XYOracleNetwork/sdk-xyobleinterface-swift

View on GitHub

Showing 3 of 19 total issues

Function prepare has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
Open

override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
do {
if (segue.identifier == "showView") {
let upcoming: ByteListViewController = segue.destination as! ByteListViewController
Severity: Minor
Found in SampleiOS/SampleiOS/ViewController.swift - About 35 mins to fix

Avoid too many return statements within this function.
Open

return false
Severity: Major
Found in sdk-xyobleinterface-swift/devices/XyoDifferentiableDevice.swift - About 30 mins to fix

    Function attachPeripheral has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
    Open

    override public func attachPeripheral(_ peripheral: XYPeripheral) -> Bool {
    guard let major = self.iBeacon?.major else {
    return false
    }
    Severity: Minor
    Found in sdk-xyobleinterface-swift/devices/XyoDifferentiableDevice.swift - About 25 mins to fix
    Severity
    Category
    Status
    Source
    Language