contains always confuses me
Refactor: improve readability.
Mess of nested functions, extract.
really sort this time