Skip to content

Commit

Permalink
chore: remove extra validationError
Browse files Browse the repository at this point in the history
as @clarkdo mentioned
  • Loading branch information
pi0 committed Aug 25, 2018
1 parent 608b913 commit 87d3038
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
5 changes: 2 additions & 3 deletions lib/app/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -292,15 +292,14 @@ async function render (to, from, next) {

// Call .validate()
let isValid = true
let validationError
try {
for (const Component of Components) {
if (typeof Component.options.validate !== 'function') {
continue
}

isValid = await Component.options.validate(app.context)

if (!isValid) {
break
}
Expand Down
1 change: 0 additions & 1 deletion lib/app/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ export default async (ssrContext) => {
** Call .validate()
*/
let isValid = true
let validationError
try {
for (const Component of Components) {
if (typeof Component.options.validate !== 'function') {
Expand Down

0 comments on commit 87d3038

Please sign in to comment.