Last active
June 27, 2018 23:04
-
-
Save diego3g/79aa2408f63ac32bb3b1254f4dda5b0d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict" | |
const User = use("App/Models/User") | |
class UserController { | |
async create ({ request }) { | |
const data = request.only(["username", "email", "password"]) | |
const user = await User.create(data) | |
return user | |
} | |
} | |
module.exports = UserController |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment