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

Merge user_model/main into main #975

Merged
merged 231 commits into from
Mar 6, 2024
Merged

Merge user_model/main into main #975

merged 231 commits into from
Mar 6, 2024

Conversation

jennantilla
Copy link
Contributor

@jennantilla jennantilla commented Feb 12, 2024

Description

One Line Summary

This PR will merge user_model/main changes into main.

Details

See here for a comparison of this branch vs. user_model/main. After this PR, main and user_model/main should be equivalent.

Note: main and user model diverged on January 4, 2023.

I have compared all changes on main and cherry-picked the merge commits.

To make the main branch reflect v5.x.x., the "old" main branch is maintained in branch 3.x.x_patch_branch.

Testing

Manual testing

Built and ran new branch on Android 13 emulator and iOS 17.2 emulator. Tested various methods to ensure everything is working.

Checklist

Overview

  • I have filled out all REQUIRED sections above
  • PR does one thing
    • If it is hard to explain how any codes changes are related to each other then it most likely needs to be more than one PR
  • Any Public API changes are explained in the PR details and conform to existing APIs

Testing

  • I have included test coverage for these changes, or explained why they are not needed
  • All automated tests pass, or I explained why that is not possible
  • I have personally tested this on my device, or explained why that is not possible

Final pass

  • Code is as readable as possible.
    • Simplify with less code, followed by splitting up code into well named functions and variables, followed by adding comments to the code.
  • I have reviewed this PR myself, ensuring it meets each checklist item
    • WIP (Work In Progress) is ok, but explain what is still in progress and what you would like feedback on. Start the PR title with "WIP" to indicate this.

This change is Reviewable

Remove logging from OneSignalPlugin class, separate log and visual level into distinct methods, update iOS header and implementation files
Remove Outcomes methods and imports from OneSignalPlugin class, update method names, update iOS header and implementation files
Remove Location methods from OneSignalPlugin class, update method names, update iOS header and implementation files
Remove In-App Messages methods from OneSignalPlugin class, update method names, update iOS header and implementation files
Remove User methods from OneSignalPlugin class, create new methods for Alias, update method names, update iOS header and implementation files
Update imports and initialization code so that iOS 5.0.0-alpha-02 can be tested on branch
Remove Push Subscription methods from OneSignalPlugin class, create new methods for opt in & property getters, update method names, update iOS header and implementation files
Update imports and initialization code so that iOS 5.0.0-alpha1 can be tested on branch
Create Alias methods, update method names, remove deprecated methods
Add setAlertLevel and update method calls
Add Alias methods, rename existing methods, remove deprecated methods
Remove "Number" suffix of method name for conformity between SDKs.
New method names conform to v5.0.0-beta1  conventions
Update privacy methods and create login/logout methods
Update SDK to 5.0.0-beta1 and OneSignalWrapper import to allow setSdkType
Update method names for Session namespace
[User Model] Create pushSubscription Namespace
`addAlias` string method improvement &
`removeAliases` updated to take in `Collection<String> labels`
jennantilla and others added 25 commits February 23, 2024 17:14
Update Migration Guide
* Extract functionality to translate `null` and empty string ("") into NULL objects, into helper methods as they are used in multiple places.
Instead of returning an object with a boolean value
- Create new async methods
- Mark old getters as deprecated
- Ensure ids are nullable and remove undefined
- Update push optedIn getter to return boolean in callback
* Instead of making dictionaries just to pass strings over the bridge, pass the strings directly, when appropriate.
* Do this by creating helper methods in iOS and Android called `callbackSuccessString` and `successCallbackString`.
* To explain why they are still there
* Move Android requestPermission resolving into the bridge to improve readability of the method.
Add getters and observer for onesignal ID and external ID
Update Push Subscription/Permission Getters to Async
[README] Removed some 404 links
Adding a new github action that allows us to measure issue response time
@jennantilla jennantilla merged commit cb45da1 into main Mar 6, 2024
3 checks passed
@jennantilla jennantilla deleted the user_model_rebase branch March 6, 2024 00:03
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.

4 participants