Moving some common utils to a single place