Changeset 2222

Show
Ignore:
Timestamp:
25-04-12 00:10:19 (2 years ago)
Author:
work@…
Message:

one return statement instead of two

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/services/api/ApiService.groovy

    r2217 r2222  
    7070     */ 
    7171    def validateRequest(String deviceID, String validation) { 
     72        def validated = false 
     73 
    7274        // disable validation check on development and ci 
    7375        if (['development', 'ci'].contains(grails.util.GrailsUtil.environment)) { 
     
    8890 
    8991            // check if the validation confirms 
    90             return (validation == validationSum) 
    91         } else { 
    92             // no such token, re-authenticate 
    93             return false 
    94         } 
     92            validated = (validation == validationSum) 
     93        } 
     94 
     95        return validated 
    9596    } 
    9697