# HG changeset patch # User jbe # Date 1425072787 -3600 # Node ID 7038084185435f3681aa4ec99e6d21827396664d # Parent 17baf126ea8822000e4205bbd81358787fab31f4 Added missing request.get_path() function diff -r 17baf126ea88 -r 703808418543 framework/env/request/get_path.lua --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/framework/env/request/get_path.lua Fri Feb 27 22:33:07 2015 +0100 @@ -0,0 +1,15 @@ +--[[-- +path = +request.get_path() + +Returns the path in the URL of the request. + +--]]-- + +function request.get_path() + local path = request._http_request.path + if not path then + error("No valid path for HTTP request") + end + return path +end