Advertisement
Guest User

Untitled

a guest
Jun 28th, 2017
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.44 KB | None | 0 0
  1. import org.codehaus.groovy.grails.commons.GrailsApplication
  2. import grails.util.GrailsUtil
  3.  
  4. class ErrorController {
  5.  
  6. def index() {
  7. if ( GrailsApplication.ENV_PRODUCTION == GrailsUtil.environment ) {
  8. // Production: show a nice error message
  9. render(view:'production')
  10. } else {
  11. // Not it production? show an ugly, developer-focused error message
  12. render(view:'development')
  13. }
  14. }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement