[fix] change functions to static functions