Fix a few more SwiftLint errors
This commit is contained in:
parent
d05525ad01
commit
4d7b8a01f5
@ -3,6 +3,8 @@ disabled_rules:
|
||||
- trailing_comma
|
||||
- todo
|
||||
- type_body_length
|
||||
- cyclomatic_complexity
|
||||
- function_body_length
|
||||
opt_in_rules: # some rules are turned off by default, so you need to opt-in
|
||||
- empty_count # Find all the available rules by running: `swiftlint rules`
|
||||
|
||||
@ -11,6 +13,7 @@ excluded: # paths to ignore during linting. Takes precedence over `included`.
|
||||
|
||||
# Adjust rule numbers
|
||||
line_length: 160
|
||||
file_length: 500
|
||||
|
||||
# reporter type (xcode, json, csv, checkstyle, codeclimate, junit, html, emoji, sonarqube, markdown, github-actions-logging)
|
||||
reporter: "xcode"
|
||||
|
@ -37,7 +37,10 @@ extension CameraView: AVCaptureMetadataOutputObjectsDelegate {
|
||||
|
||||
private func invokeOnCodeScanned(codes: [[String: Any]?]) {
|
||||
guard let onCodeScanned = self.onCodeScanned else {
|
||||
ReactLogger.log(level: .warning, message: "onCodeScanned was invoked with no listeners. This means that the Camera is unnecessarily scanning codes. This indicates a memory leak.", alsoLogToJS: true)
|
||||
ReactLogger.log(level: .warning,
|
||||
message: "onCodeScanned was invoked with no listeners. " +
|
||||
"This means that the Camera is unnecessarily scanning codes. This indicates a memory leak.",
|
||||
alsoLogToJS: true)
|
||||
return
|
||||
}
|
||||
onCodeScanned(["codes": codes])
|
||||
|
@ -25,6 +25,7 @@ import UIKit
|
||||
// CameraView+TakePhoto
|
||||
// TODO: Photo HDR
|
||||
|
||||
// swiftlint:disable line_length
|
||||
private let propsThatRequireReconfiguration = ["cameraId", "enableDepthData", "enableHighResolutionCapture", "enablePortraitEffectsMatteDelivery", "preset", "onCodeScanned", "scannableCodes"]
|
||||
private let propsThatRequireDeviceReconfiguration = ["fps", "hdr", "lowLightBoost", "colorSpace"]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user