move module.exports declaration to bottom