Skip to content

Commit 2082bb8

Browse files
committed
v14.1.0
1 parent 65a8db5 commit 2082bb8

File tree

10 files changed

+84
-36
lines changed

10 files changed

+84
-36
lines changed

android/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ repositories {
5656

5757
dependencies {
5858
implementation "com.facebook.react:react-native:+"
59-
implementation group: 'io.gleap', name: 'gleap-android-sdk', version: '14.0.5'
59+
implementation group: 'io.gleap', name: 'gleap-android-sdk', version: '14.1.0'
6060

6161
if(rootProject && rootProject.ext) {
6262
if(rootProject.ext.targetSdkVersion == 30 || rootProject.ext.compileSdkVersion == 30) {

android/src/main/java/com/reactnativegleapsdk/GleapsdkModule.java

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -866,6 +866,27 @@ public void setTicketAttribute(String key, String value) {
866866
Gleap.getInstance().setTicketAttribute(key, value);
867867
}
868868

869+
/**
870+
* Unset the value for a ticket attribute with key.
871+
*
872+
* @param key The key of the attribute
873+
* @author Gleap
874+
*/
875+
@ReactMethod
876+
public void unsetTicketAttribute(String key) {
877+
Gleap.getInstance().unsetTicketAttribute(key);
878+
}
879+
880+
/**
881+
* Clears all ticket attributes.
882+
*
883+
* @author Gleap
884+
*/
885+
@ReactMethod
886+
public void clearTicketAttributes() {
887+
Gleap.getInstance().clearTicketAttributes();
888+
}
889+
869890
/**
870891
* Removes one key from existing custom data.
871892
*

example/index.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,11 @@ Gleap.setAiTools(tools);
4242

4343
Gleap.setTicketAttribute('note', 'This is a test value.');
4444

45-
Gleap.initialize('nKT6erqDUjwqfVN2xRkOG4XOf8NEEJ52');
45+
Gleap.unsetTicketAttribute('note');
46+
47+
Gleap.clearTicketAttributes();
48+
49+
Gleap.initialize('ogWhNhuiZcGWrva5nlDS8l7a78OfaLlV');
4650

4751
Gleap.registerCustomAction(customAction => {
4852
console.log('customAction', JSON.stringify(customAction, null, 2));

example/ios/Podfile.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ PODS:
1010
- React-jsi (= 0.71.11)
1111
- ReactCommon/turbomodule/core (= 0.71.11)
1212
- fmt (6.2.1)
13-
- Gleap (14.0.5)
13+
- Gleap (14.1.0)
1414
- glog (0.3.5)
1515
- hermes-engine (0.71.11):
1616
- hermes-engine/Pre-built (= 0.71.11)
@@ -267,8 +267,8 @@ PODS:
267267
- React-jsinspector (0.71.11)
268268
- React-logger (0.71.11):
269269
- glog
270-
- react-native-gleapsdk (14.0.5):
271-
- Gleap (= 14.0.5)
270+
- react-native-gleapsdk (14.1.0):
271+
- Gleap (= 14.1.0)
272272
- React-Core
273273
- React-perflogger (0.71.11)
274274
- React-RCTActionSheet (0.71.11):
@@ -479,7 +479,7 @@ SPEC CHECKSUMS:
479479
FBLazyVector: c511d4cd0210f416cb5c289bd5ae6b36d909b048
480480
FBReactNativeSpec: a911fb22def57aef1d74215e8b6b8761d25c1c54
481481
fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9
482-
Gleap: 5d885579f3f8b9f462dc92d1b802a741f47aee88
482+
Gleap: 58daf19a83adfae6d354b3187c560cd0d9568d34
483483
glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b
484484
hermes-engine: 34c863b446d0135b85a6536fa5fd89f48196f848
485485
libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913
@@ -497,7 +497,7 @@ SPEC CHECKSUMS:
497497
React-jsiexecutor: 18b5b33c5f2687a784a61bc8176611b73524ae77
498498
React-jsinspector: b6ed4cb3ffa27a041cd440300503dc512b761450
499499
React-logger: 186dd536128ae5924bc38ed70932c00aa740cd5b
500-
react-native-gleapsdk: 85e64405e286888832b5e47d70194a7ccd51b960
500+
react-native-gleapsdk: 8243c6a83cd601e52db8e572de171a2a6767fd72
501501
React-perflogger: e706562ab7eb8eb590aa83a224d26fa13963d7f2
502502
React-RCTActionSheet: 57d4bd98122f557479a3359ad5dad8e109e20c5a
503503
React-RCTAnimation: ccf3ef00101ea74bda73a045d79a658b36728a60

example/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ios/Gleapsdk.m

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -599,6 +599,18 @@ - (void)stopObserving
599599
});
600600
}
601601

602+
RCT_EXPORT_METHOD(unsetTicketAttribute:(NSString *)key) {
603+
dispatch_async(dispatch_get_main_queue(), ^{
604+
[Gleap unsetTicketAttributeWithKey: key];
605+
});
606+
}
607+
608+
RCT_EXPORT_METHOD(clearTicketAttributes) {
609+
dispatch_async(dispatch_get_main_queue(), ^{
610+
[Gleap clearTicketAttributes];
611+
});
612+
}
613+
602614
RCT_EXPORT_METHOD(setAiTools:(NSArray *)toolsArray) {
603615
dispatch_async(dispatch_get_main_queue(), ^{
604616
@try {

package-lock.json

Lines changed: 35 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-native-gleapsdk",
3-
"version": "14.0.5",
3+
"version": "14.1.0",
44
"description": "Know exactly why and how a bug happened. Get reports with screenshots, live action replays and all of the important metadata every time.",
55
"main": "lib/commonjs/index",
66
"module": "lib/module/index",

react-native-gleapsdk.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@ Pod::Spec.new do |s|
1616
s.source_files = "ios/**/*.{h,m,mm}"
1717

1818
s.dependency "React-Core"
19-
s.dependency "Gleap", "14.0.5"
19+
s.dependency "Gleap", "14.1.0"
2020
end

src/index.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,8 @@ type GleapSdkType = {
104104
getIdentity(): Promise<any>;
105105
isUserIdentified(): Promise<boolean>;
106106
setTicketAttribute(key: string, value: string): void;
107+
unsetTicketAttribute(key: string): void;
108+
clearTicketAttributes(): void;
107109
setAiTools(
108110
tools: {
109111
name: string;

0 commit comments

Comments
 (0)