@@ -0,0 +1,637 @@
+const db = require('../db/config');%0A%0Aconst User = %7B%7D;%0A%0AUser.findByUserName = userName =%3E %7B%0A    return db.oneOrNone(%60%0A        SELECT * FROM users%0A        WHERE username = $1%0A    %60, %5BuserName%5D);%0A%7D;%0A%0AUser.create = user =%3E %7B%0A    return db.one(%60%0A        INSERT INTO users%0A        (username, password_digest, email, first_name, last_name)%0A        VALUES ($1, $2, $3, $4, $5)%0A        RETURNING *%0A    %60, %5Buser.username, user.password_digest, user.email, user.first_name, user.last_name%5D);%0A%7D;%0A%0AUser.findByUserId = id =%3E %7B%0A    return db.manyOrNone(%60%0A        SELECT * FROM profile%0A        WHERE user_id = $1%0A    %60, %5Bid%5D);%0A%7D;%0A%0Amodule.exports = User;

create user models