Skip to content

Commit

Permalink
push adoption of platform info in serialized files
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyGamer13 authored Apr 21, 2024
1 parent 11eec66 commit 56addcc
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/serialization/sb3.js
Original file line number Diff line number Diff line change
Expand Up @@ -794,6 +794,13 @@ const serialize = function (runtime, targetId, {allowOptimization = true} = {})
// TW: Never include full user agent to slightly improve user privacy
// if (typeof navigator !== 'undefined') meta.agent = navigator.userAgent;

// TW: Attach platform information (should be changed for forks of TurboWarp)
const platform = Object.create(null);
platform.name = "TurboWarp";

Check failure on line 799 in src/serialization/sb3.js

View workflow job for this annotation

GitHub Actions / build

Strings must use singlequote
platform.url = "https://turbowarp.org/";

Check failure on line 800 in src/serialization/sb3.js

View workflow job for this annotation

GitHub Actions / build

Strings must use singlequote
platform.version = "stable"; // Can be changed on staging?

Check failure on line 801 in src/serialization/sb3.js

View workflow job for this annotation

GitHub Actions / build

Strings must use singlequote
meta.platform = platform;

// Assemble payload and return
obj.meta = meta;

Expand Down

0 comments on commit 56addcc

Please sign in to comment.