const express = require('express')
const router = express.Router()
const { registerValidationRules, registerUser } = require('../../../controllers/application/register/registerController')
const { verifyUser } = require('../../../controllers/application/register/verifyController')
const { setUserName, updateUserName } = require('../../../controllers/application/register/usernameController')
const { setUserFullName, setUserFullNameValidationRules } = require('../../../controllers/application/register/userFullNameController')
const { setUserType } = require('../../../controllers/application/register/userTypeController')

router.post('/', registerValidationRules(), registerUser)
router.post('/verify', verifyUser)
router.post('/username', setUserName)
router.patch('/username', updateUserName)
router.post('/fullname', setUserFullNameValidationRules(), setUserFullName)
router.post('/user_type', setUserType)

module.exports = router
