Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,32 @@
## 4.0.2 (2025-12-09)


* [DEV-359] feat!(main): support expo apps, rm native module. Kudos https://github.com/ahmetkuslular (dc9762c)


### Bug Fixes

* **gcm:** message variability (544eb08)


### Features

* **common:** bump version (ce7e70d)
* **sdk:** bump device-info (1d1f10e)
* **sdk:** getToken to use correct token (d07df14)
* **sdk:** in-app push notifications (#51) (6fa0296)
* **sdk:** include types for exclude_brands (#50) (cd1d301)
* **sdk:** rm jest (d0cce5d)
* **sdk:** sid token generation (4a34846)


### BREAKING CHANGES

* rm react-native-device-info, dynamically import if
needed



## 4.0.1 (2025-10-27)


Expand Down
24 changes: 15 additions & 9 deletions MainSDK.js
Original file line number Diff line number Diff line change
Expand Up @@ -502,21 +502,27 @@ class MainSDK extends Performer {
setPushTokenNotification(token) {
this.push(async () => {
try {
const params = {
token: token,
platform:
this._push_type !== null
? this._push_type
: token.match(/[a-z]/) !== null
? 'android'
: 'ios',
let platform

if (this._push_type !== null) {
platform = this._push_type
} else {
if (Platform.OS === 'ios') {
platform = 'ios'
} else {
platform = 'android'
}
}

if (DEBUG) console.log(`Push token platform: '${platform}'`)

return await request('mobile_push_tokens', this.shop_id, {
method: 'POST',
params: {
shop_id: this.shop_id,
stream: this.stream,
...params,
token,
platform,
},
}).then(async (data) => {
if (data.status === 'success') {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@personaclick/rn-sdk",
"version": "4.0.1",
"version": "4.0.2",
"description": "PersonaClick React Native SDK",
"type": "module",
"exports": {
Expand Down