Skip to content

Commit 149ab5b

Browse files
committed
Replaced getRightBtn() in buttons.insert() w/ .rightBtn already init'd in .create()
1 parent 52c8742 commit 149ab5b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

chatgpt-widescreen/chromium/extension/components/buttons.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ window.buttons = {
136136
const chatbarDiv = await chatbar.get() ; if (!chatbarDiv) return this.state.status = 'missing'
137137
const btnTypesToInsert = this.getTypes.valid()
138138
const parentToInsertInto = (
139-
this.imports.env.site == 'chatgpt' ? (await this.getRightBtn()).closest('[class*=bottom]') // right btn div
139+
this.imports.env.site == 'chatgpt' ? this.rightBtn.closest('[class*=bottom]') // right btn div
140140
: chatbarDiv.lastChild ) // parent of [Perplexity right btns or Poe Mic/Send btns]
141141
const elemToInsertBefore = parentToInsertInto[
142142
this.imports.env.site == 'chatgpt' ? 'lastChild' // right btn

chatgpt-widescreen/firefox/extension/components/buttons.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ window.buttons = {
136136
const chatbarDiv = await chatbar.get() ; if (!chatbarDiv) return this.state.status = 'missing'
137137
const btnTypesToInsert = this.getTypes.valid()
138138
const parentToInsertInto = (
139-
this.imports.env.site == 'chatgpt' ? (await this.getRightBtn()).closest('[class*=bottom]') // right btn div
139+
this.imports.env.site == 'chatgpt' ? this.rightBtn.closest('[class*=bottom]') // right btn div
140140
: chatbarDiv.lastChild ) // parent of [Perplexity right btns or Poe Mic/Send btns]
141141
const elemToInsertBefore = parentToInsertInto[
142142
this.imports.env.site == 'chatgpt' ? 'lastChild' // right btn

0 commit comments

Comments
 (0)