Original "Create pull request button" isn't removed #3914
mischnic posted onGitHub
Refined Github adds a separate button for a draft PR, but the original button isn't removed:
Last change broke the feature on GHE as well, I'll see if I can fix both sometime this week.
I can't recreate this 🤷 Tried Dark Mode too and the button is gone. Do you have any other extensions running? I'd guess another is interfering with it or you're in some beta group I am not.
Strange, I don't get it here:
https://github.com/sindresorhus/refined-github/compare/unknow-feature-name?expand=1
but for example here:
https://github.com/parcel-bundler/parcel/compare/abstract-fs-part-2?expand=1
The only difference I can think of is that I have push access to the Parcel repo.
Same problem spotted on a private repository, I have 3 buttons.
Strangely I can't replicate it. Do you see any errors in the console?
<img width="693" alt="Screen Shot" src="https://user-images.githubusercontent.com/1402241/106211972-3b6aba80-618f-11eb-945d-94f076e6602c.png">
Yes:
refined-github.js:2134 ❌ Refined GitHub → separate-draft-pr-button → TypeError: Cannot read property 'name' of undefined
at init (refined-github.js:6722)
at runFeature (refined-github.js:2152)
at setupPageLoad (refined-github.js:2160)
at refined-github.js:2193
Search issue: https://github.com/sindresorhus/refined-github/issues?q=is%3Aissue+Cannot%20read%20property%20'name'%20of%20undefined
Open an issue: https://github.com/sindresorhus/refined-github/issues/new?labels=bug&template=bug_report.md&title=%60separate-draft-pr-button%60%3A%20Cannot%20read%20property%20'name'%20of%20undefined
In the loop iteration where the error is thrown, dropdownItem
here
is this element:
<img width="768" alt="Bildschirmfoto 2021-01-29 um 00 42 36" src="https://user-images.githubusercontent.com/4586894/106212423-e482d680-61ca-11eb-9771-3b4f1a14b690.png">
where <details>
at the very top is the assignee menu:
<img width="1302" alt="Bildschirmfoto 2021-01-29 um 00 40 00" src="https://user-images.githubusercontent.com/4586894/106212271-8655f380-61ca-11eb-8e67-3e1b1550b1d6.png">
If I'm not a member of the repo, there is no assignee/reviewer dropdown at all. So that would explain the differing behaviour on my side.