cleaned up helper.js