Commit a09ce30
fix: ad references, terminal HTTP safety, banner sync, and defense fixes (#2169)
* fix: ad references, terminal HTTP safety, banner sync, and defense fixes
- Replace window.ad/window.iad with module-level bannerAd/interstitialAd
imports from startAd.js across adRewards, helpers, keyboard, remoteStorage,
plugin, and extensions modules
- Export ad unit IDs, bannerAd, interstitialAd, and initialized from startAd
for consistent module-level references
- Guard terminal createPid/resize/terminate against missing cordova HTTP plugin
with null-safe sendRequest lookup and improved error fallback
- Restore admob?.RewardedAd guard in createRewardedAd and adUnitIdRewarded
check in isRewardedSupported
- Fix banner ad toggle to fire on every resume event, not just on height change
- Skip system.clearCache on fresh install by adding previousVersionCode != null
check
- Escape regex special chars in font name before building @font-face regex
- Add error logging to previously silent catch block in devTools eruda download
- Restore rating-medium CSS class for 50-79% plugin ratings in plugin.view.js
- Fix ES6 detection in index.html by invoking the returned arrow function
- Add trailing newline to index.html
Or a shorter version:
fix: tighten ad references, terminal safety, and defensive fixes
Replace global window.ad/window.iad with module-level exports from startAd.js.
Add cordova HTTP plugin availability guards in terminal (create/resize/terminate).
Restore missing safety checks in adRewards (RewardedAd guard, unit ID check).
Fix banner ad not syncing on resume without keyboard height change, skip
clearCache on fresh install, escape font name in regex, and fix silent catch
in devTools eruda download.
* fix: linting
* fix: review changes
---------
Co-authored-by: Ajit Kumar <dellevenjack@gmail>1 parent c1ff3f7 commit a09ce30
48 files changed
Lines changed: 829 additions & 519 deletions
File tree
- src
- components
- audioPlayer
- lspInfoDialog
- lspStatusBar
- referencesPanel
- sideButton
- sidebar
- symbolsPanel
- terminal
- handlers
- lib
- pages
- about
- adRewards
- changelog
- fileBrowser
- fontManager
- markdownPreview
- plugins
- plugin
- quickTools
- sponsors
- sponsor
- themeSetting
- welcome
- plugins
- admob/src/android
- cordova/ads
- core
- system/www
- sidebarApps
- extensions
- notification
- styles
- utils
- www
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
41 | 42 | | |
42 | 43 | | |
43 | 44 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
44 | 43 | | |
45 | 44 | | |
46 | 45 | | |
47 | | - | |
| 46 | + | |
| 47 | + | |
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| |||
194 | 194 | | |
195 | 195 | | |
196 | 196 | | |
197 | | - | |
| 197 | + | |
198 | 198 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | 29 | | |
40 | 30 | | |
41 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
1 | 6 | | |
2 | 7 | | |
3 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
454 | 454 | | |
455 | 455 | | |
456 | 456 | | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
| 472 | + | |
457 | 473 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
166 | 174 | | |
167 | 175 | | |
168 | 176 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
298 | 298 | | |
299 | 299 | | |
300 | 300 | | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
301 | 316 | | |
302 | 317 | | |
303 | 318 | | |
| |||
0 commit comments