Skip to content

Commit

Permalink
[master] - 'Make SonarQube happy - TT'
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyler-Keith-Thompson committed Dec 25, 2019
1 parent e756352 commit 1260d75
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 31 deletions.
4 changes: 2 additions & 2 deletions DependencyInjection/DependencyInjected.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public struct DependencyInjected<Value> {
let container:Container

public init(wrappedValue value: Value?) {
self.name = nil
name = nil
container = Workflow.defaultContainer
}
public init(wrappedValue value: Value? = nil, name:String) {
Expand All @@ -25,7 +25,7 @@ public struct DependencyInjected<Value> {

public init(wrappedValue value: Value? = nil, container containerGetter:@autoclosure () -> Container, name:String? = nil) {
self.name = name
self.container = containerGetter()
container = containerGetter()
}

public lazy var wrappedValue: Value? = {
Expand Down
24 changes: 1 addition & 23 deletions Workflow/LinkedList/LinkedList.swift
Original file line number Diff line number Diff line change
Expand Up @@ -45,32 +45,10 @@ public class LinkedList<Value> : Sequence, CustomStringConvertible {
/// - Complexity: O(n). The LinkedList must traverse to the end to determine the count
public var last : Element? { return first?.traverseToEnd() }

// /** init(arrayLiteral): A LinkedList can be instantiated with an array literal
// ### Example:
// ```swift
// let list:LinkedList<Int> = [1, 2, 3, 4]
// ```
// */
// required public convenience init(arrayLiteral elements: Value...) {
// self.init(elements)
// }
//
// /** init(elements): A LinkedList can be instantiated with variadic arguments
// ### Example:
// ```swift
// let list = LinkedList<Int>(1, 2, 3, 4)
// ```
// */
public convenience init(_ elements: Value...) {
self.init(elements)
}
//
// /** init(elements): A LinkedList can be instantiated with an array
// ### Example:
// ```swift
// let list = LinkedList<Int>([1, 2, 3, 4])
// ```
// */

public convenience init(_ elements: [Value]) {
let collection = elements.map { Element(with: $0) }
for (i, node) in collection.enumerated() {
Expand Down
5 changes: 0 additions & 5 deletions Workflow/LinkedList/NonMutatingOperations.swift
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,4 @@ extension LinkedList {
copy?.previous = nil
return LinkedList(copy)
}

// public func split(maxSplits: Int = Int.max, omittingEmptySubsequences: Bool = true, whereSeparator isSeparator: (Element) throws -> Bool) rethrows -> [SubSequence] {
// let splitNodeArr = (try? map { $0 }.split(maxSplits: maxSplits, omittingEmptySubsequences: omittingEmptySubsequences, whereSeparator: isSeparator)) ?? []
// return splitNodeArr.map { SubSequence($0.map { $0.value }) }
// }
}
4 changes: 3 additions & 1 deletion Workflow/Models/BasePresenter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,7 @@ import Foundation
open class BasePresenter<T> {
public typealias ViewType = T

required public init() { }
required public init() {
//Meant to be called from subclasses, but presenters *must* contain an empty initializer
}
}

0 comments on commit 1260d75

Please sign in to comment.