Skip to content

Commit 5b4d56c

Browse files
fix(github): injection when editFileButton is null (#68)
1 parent c9ad03f commit 5b4d56c

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ For Chrome:
4646
For Firefox
4747

4848
1. Open Firefox
49-
1. Click Preferences -> Extensions & Themes
50-
1. Click on the cog icon -> Install Add-on From File -> Select the `gitpod.xpi` file
49+
1. Go to `about:debugging#/runtime/this-firefox`
50+
1. Click Load Temporary Add-on -> Select the `gitpod.xpi` file
5151

5252
For Safari (Experimental 🧪)
5353

manifest.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"manifest_version": 2,
33
"name": "Gitpod - Always ready to code",
44
"short_name": "Gitpod",
5-
"version": "1.16",
5+
"version": "1.17",
66
"description": "Spin up fresh, automated dev environments for each task, in the cloud, in seconds.",
77
"icons": {
88
"16": "icons/gitpod-logo-16.png",

src/injectors/github-injector.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,9 @@ abstract class ButtonInjectorBase implements ButtonInjector {
122122

123123
// Edit File Menu Options - Open in Gitpod
124124
const editFileButton = document.querySelector('.Box-header .select-menu .SelectMenu-list') as ParentNode;
125-
editFileButton.prepend(this.renderEditButton(currentUrl, openAsPopup));
125+
if (editFileButton) {
126+
editFileButton.prepend(this.renderEditButton(currentUrl, openAsPopup));
127+
}
126128
}
127129

128130
protected renderButton(url: string, openAsPopup: boolean): HTMLElement {

0 commit comments

Comments
 (0)