fix problem with no routes
fix problem with picture
updated database function
updated database function
added onValidation
new controller test