Skip to content

Commit e70d288

Browse files
committed
🎨 (config): Use WebConfig._buildInfo
1 parent f23e6d0 commit e70d288

4 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/script/OptionPage.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2168,7 +2168,7 @@ export default class OptionPage {
21682168

21692169
setHelpVersion() {
21702170
const helpVersion = document.getElementById('helpVersion') as HTMLAnchorElement;
2171-
helpVersion.textContent = this.Class.Config.BUILD.version;
2171+
helpVersion.textContent = this.cfg._buildInfo.version;
21722172
}
21732173

21742174
setThemeButton(darkTheme: boolean) {

src/script/Popup.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -350,9 +350,9 @@ export default class Popup {
350350
return (
351351
!this.domain.hostname ||
352352
this.Class.Page.disabledProtocols.test(this.url.protocol) ||
353-
(this.Class.Config.BUILD.target == this.Class.Constants.BUILD_TARGET_CHROME &&
353+
(this.cfg._buildInfo.target == this.Class.Constants.BUILD_TARGET_CHROME &&
354354
this.Class.Page.disabledChromePages.includes(this.domain.hostname)) ||
355-
(this.Class.Config.BUILD.target == this.Class.Constants.BUILD_TARGET_FIREFOX &&
355+
(this.cfg._buildInfo.target == this.Class.Constants.BUILD_TARGET_FIREFOX &&
356356
this.Class.Page.disabledFirefoxPages.includes(this.domain.hostname))
357357
);
358358
}

src/script/WebConfig.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ export default class WebConfig extends Config {
352352

353353
localizeDefaults() {
354354
if (
355-
this.Class.BUILD.target === this.Class.Constants.BUILD_TARGET_BOOKMARKLET ||
355+
this._buildInfo.target === this.Class.Constants.BUILD_TARGET_BOOKMARKLET ||
356356
!this._defaultsLoaded ||
357357
!this._defaultsLoaded.length
358358
)

src/script/entry/bookmarklet.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import BookmarkletFilter from '@APF/BookmarkletFilter';
77
const config = WebConfig._defaults as WebConfig;
88
/* @preserve - End User Config */
99

10-
console.log(`[APF Bookmarklet] Activated (version ${WebConfig.BUILD.version})`);
10+
console.log(`[APF Bookmarklet] Activated (version ${config._buildInfo.version})`);
1111
if (typeof window !== 'undefined' && !(<any>window).apfBookmarklet) {
1212
(<any>window).apfBookmarklet = true;
1313
console.log('[APF Bookmarklet] Running');

0 commit comments

Comments
 (0)