change to static for external call