ruby test special string
Ruby
code posted
by
Olli
created at 27 Dec 16:58, updated at 08 Jan 16:14
Edit
|
Back
1 2 3 4 5 6 7 8 9 |
def protected! unless authorized? response['WWW-Authenticate'] = %(Basic realm="Restricted Area => your IP is (#{request.ip})") throw(:halt, [401, "Not authorized\n"]) end end def my_custom puts "i am in my custom end |
249 Bytes in 2 ms with coderay