Move implementation to more appropriate location