@applicaster/quick-brick-native-apple 5.13.3 → 5.13.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "QuickBrickApple",
|
|
3
|
-
"version": "5.13.
|
|
3
|
+
"version": "5.13.4",
|
|
4
4
|
"platforms": {
|
|
5
5
|
"ios": "12.0",
|
|
6
6
|
"tvos": "12.0"
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"authors": "Applicaster LTD.",
|
|
17
17
|
"source": {
|
|
18
18
|
"git": "https://github.com/applicaster/Zapp-Frameworks.git",
|
|
19
|
-
"tag": "@@applicaster/quick-brick-native-apple/5.13.
|
|
19
|
+
"tag": "@@applicaster/quick-brick-native-apple/5.13.4"
|
|
20
20
|
},
|
|
21
21
|
"requires_arc": true,
|
|
22
22
|
"source_files": "universal/**/*.{m,swift}",
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
//
|
|
2
|
+
// QuickBrickExceptionManager.swift
|
|
3
|
+
// QuickBrickApple
|
|
4
|
+
//
|
|
5
|
+
// Created by Alex Zchut on 02/16/22.
|
|
6
|
+
//
|
|
7
|
+
|
|
8
|
+
import os.log
|
|
9
|
+
import React
|
|
10
|
+
import UIKit
|
|
11
|
+
import XrayLogger
|
|
12
|
+
import ZappCore
|
|
13
|
+
|
|
14
|
+
class QuickBrickExceptionManager: RCTExceptionsManager, RCTExceptionsManagerDelegate {
|
|
15
|
+
public lazy var logger = Logger.getLogger(for: ReactNativeManagerLogs.subsystem)
|
|
16
|
+
|
|
17
|
+
func handleSoftJSException(withMessage message: String?, stack: [Any]?, exceptionId: NSNumber) {
|
|
18
|
+
guard let message = message,
|
|
19
|
+
let stack = stack else {
|
|
20
|
+
return
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
let logOrigin = OSLog(subsystem: "\(Self.self)", category: "handleSoftJSException")
|
|
24
|
+
os_log("handleSoftJSException message: %@, stack: %@",
|
|
25
|
+
log: logOrigin,
|
|
26
|
+
type: .error,
|
|
27
|
+
message, stack)
|
|
28
|
+
|
|
29
|
+
logger?.errorLog(message: ReactNativeManagerLogs.handleSoftJSException.message,
|
|
30
|
+
category: ReactNativeManagerLogs.handleSoftJSException.category,
|
|
31
|
+
data: [
|
|
32
|
+
"message": message,
|
|
33
|
+
"stack": stack,
|
|
34
|
+
"exceptionId": "\(exceptionId)",
|
|
35
|
+
])
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
func handleFatalJSException(withMessage message: String?, stack: [Any]?, exceptionId: NSNumber) {
|
|
39
|
+
guard let message = message,
|
|
40
|
+
let stack = stack else {
|
|
41
|
+
return
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
let logOrigin = OSLog(subsystem: "\(Self.self)", category: "handleFatalJSException")
|
|
45
|
+
os_log("handleFatalJSException message: %{public}@, stack: %{public}@",
|
|
46
|
+
log: logOrigin,
|
|
47
|
+
type: .error,
|
|
48
|
+
message, stack)
|
|
49
|
+
|
|
50
|
+
logger?.errorLog(message: ReactNativeManagerLogs.handleFatalJSException.message,
|
|
51
|
+
category: ReactNativeManagerLogs.handleFatalJSException.category,
|
|
52
|
+
data: [
|
|
53
|
+
"message": message,
|
|
54
|
+
"stack": stack,
|
|
55
|
+
"exceptionId": "\(exceptionId)",
|
|
56
|
+
])
|
|
57
|
+
}
|
|
58
|
+
}
|
|
@@ -171,12 +171,14 @@ extension ReactNativeManager: RCTBridgeDelegate {
|
|
|
171
171
|
return nil
|
|
172
172
|
}
|
|
173
173
|
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
174
|
+
#if os(iOS)
|
|
175
|
+
public func extraModules(for bridge: RCTBridge!) -> [RCTBridgeModule]! {
|
|
176
|
+
let qbExceptionManager = QuickBrickExceptionManager()
|
|
177
|
+
let rctException = RCTExceptionsManager(delegate: qbExceptionManager)
|
|
177
178
|
|
|
178
|
-
|
|
179
|
-
|
|
179
|
+
return [rctException, qbExceptionManager]
|
|
180
|
+
}
|
|
181
|
+
#endif
|
|
180
182
|
}
|
|
181
183
|
|
|
182
184
|
extension ReactNativeManager: QuickBrickManagerDelegate {
|
|
@@ -224,50 +226,4 @@ extension ReactNativeManager: QuickBrickManagerDelegate {
|
|
|
224
226
|
public func forceAppReload() {
|
|
225
227
|
EventsBus.post(EventsBus.Event(type: EventsBusType(.forceAppReload)))
|
|
226
228
|
}
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
class QBExceptionManager: RCTExceptionsManager, RCTExceptionsManagerDelegate {
|
|
230
|
-
public lazy var logger = Logger.getLogger(for: ReactNativeManagerLogs.subsystem)
|
|
231
|
-
|
|
232
|
-
func handleSoftJSException(withMessage message: String?, stack: [Any]?, exceptionId: NSNumber) {
|
|
233
|
-
guard let message = message,
|
|
234
|
-
let stack = stack else {
|
|
235
|
-
return
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
let logOrigin = OSLog(subsystem: "\(Self.self)", category: "handleSoftJSException")
|
|
239
|
-
os_log("handleSoftJSException message: %@, stack: %@",
|
|
240
|
-
log: logOrigin,
|
|
241
|
-
type: .error,
|
|
242
|
-
message, stack)
|
|
243
|
-
|
|
244
|
-
logger?.errorLog(message: ReactNativeManagerLogs.handleSoftJSException.message,
|
|
245
|
-
category: ReactNativeManagerLogs.handleSoftJSException.category,
|
|
246
|
-
data: [
|
|
247
|
-
"message": message,
|
|
248
|
-
"stack": stack,
|
|
249
|
-
"exceptionId": "\(exceptionId)",
|
|
250
|
-
])
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
func handleFatalJSException(withMessage message: String?, stack: [Any]?, exceptionId: NSNumber) {
|
|
254
|
-
guard let message = message,
|
|
255
|
-
let stack = stack else {
|
|
256
|
-
return
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
let logOrigin = OSLog(subsystem: "\(Self.self)", category: "handleFatalJSException")
|
|
260
|
-
os_log("handleFatalJSException message: %{public}@, stack: %{public}@",
|
|
261
|
-
log: logOrigin,
|
|
262
|
-
type: .error,
|
|
263
|
-
message, stack)
|
|
264
|
-
|
|
265
|
-
logger?.errorLog(message: ReactNativeManagerLogs.handleFatalJSException.message,
|
|
266
|
-
category: ReactNativeManagerLogs.handleFatalJSException.category,
|
|
267
|
-
data: [
|
|
268
|
-
"message": message,
|
|
269
|
-
"stack": stack,
|
|
270
|
-
"exceptionId": "\(exceptionId)",
|
|
271
|
-
])
|
|
272
|
-
}
|
|
273
|
-
}
|
|
229
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@applicaster/quick-brick-native-apple",
|
|
3
|
-
"version": "5.13.
|
|
3
|
+
"version": "5.13.4",
|
|
4
4
|
"description": "iOS and tvOS native code for QuickBrick applications. This package is used to provide native logic for QuickBrick",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"test": "echo \"Error: no test specified\" && exit 1"
|