Skip to content

Commit

Permalink
added back to request
Browse files Browse the repository at this point in the history
  • Loading branch information
josephmancuso committed Jan 16, 2018
1 parent dc48d82 commit d945531
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions masonite/request.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,11 @@ def redirectTo(self, route):
self.redirect_route = route
return self

def back(self, input_parameter='back'):
''' Go to a named route with the back parameter '''
self.redirectTo(self.input(input_parameter))
return self

def compile_route_to_url(self):
''' Compile the route url into a usable url
Converts /url/@id into /url/1. Used for redirection
Expand Down

0 comments on commit d945531

Please sign in to comment.