improve helper method impl