Skip to content

Commit

Permalink
Ensuring non null calls on some helper methods.
Browse files Browse the repository at this point in the history
  • Loading branch information
Antoine Neveux a183276 committed Oct 26, 2016
1 parent 55c98e4 commit 3693baa
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ import com.github.ktoolz.filefinder.model.BangQuery
import com.github.ktoolz.filefinder.model.SearchQuery
import javaslang.collection.List

fun List<Bang>.names() = this.map { it.name }
fun List<Bang>.findBang(name: String) = this.find { it.name.equals(name) }.get()
fun List<Bang>.names() = this.map { it.name }!!
fun List<Bang>.findBang(name: String) = this.find { it.name == name }.get()!!

class ContextParser(val bangsReferences: List<Bang>,
val bangsIdentifier: Char = '!',
Expand Down

0 comments on commit 3693baa

Please sign in to comment.