fixed validation, now new errors need to be fixed before moving to storage
adding validate js