Placed the functions in a wrong part of code, it would never get executed