Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix web info #18

Merged
merged 1 commit into from
Dec 18, 2024
Merged

Fix web info #18

merged 1 commit into from
Dec 18, 2024

Conversation

GabrielRozendo
Copy link
Contributor

Related to item 3 in #13. Quoting:

3. Fix web info

In web is flagging OS as unknown.
In package DeviceInfoPlugin has the implementation for web platform, check out in pub.dev example

Already change to use the webBrowserInfo

CleanShot 2024-09-03 at 13 09 36

The issue here is the version part as the web provides not a clear single option to use.

In documentation has these info:

 Map<String, dynamic> _readWebBrowserInfo(WebBrowserInfo data) {
    return <String, dynamic>{
      'browserName': data.browserName.name,
      'appCodeName': data.appCodeName,
      'appName': data.appName,
      'appVersion': data.appVersion,
      'deviceMemory': data.deviceMemory,
      'language': data.language,
      'languages': data.languages,
      'platform': data.platform,
      'product': data.product,
      'productSub': data.productSub,
      'userAgent': data.userAgent,
      'vendor': data.vendor,
      'vendorSub': data.vendorSub,
      'hardwareConcurrency': data.hardwareConcurrency,
      'maxTouchPoints': data.maxTouchPoints,
    };
  }

Here is my debug value:
CleanShot 2024-09-03 at 12 55 04@2x

We could use the appVersion but still not so clear and simple.
And yet we should limit it to 100 max chars as server defined.
39: osInfo.version.substring(0, 100),

@cristipufu cristipufu merged commit 8079602 into aptabase:main Dec 18, 2024
@GabrielRozendo GabrielRozendo deleted the fix_web_info branch December 19, 2024 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants