Refactor of Redeemer controller in JavaScript complete