Updated Node.js code to matchup with the client-side API code that's being used. Fixed checkUnique issue.