mirror of
https://github.com/neocities/neocities.git
synced 2025-04-25 01:32:36 +02:00
only render tutorial page if number 1-10
This commit is contained in:
parent
1beedb79b1
commit
4ffeddaf5a
1 changed files with 1 additions and 1 deletions
|
@ -31,7 +31,7 @@ end
|
||||||
get '/tutorial/:section/:page/?' do
|
get '/tutorial/:section/:page/?' do
|
||||||
require_login
|
require_login
|
||||||
@page = params[:page]
|
@page = params[:page]
|
||||||
not_found if @page.to_i == 0
|
not_found unless @page.match?(/\A[1-9]\z|\A10\z/)
|
||||||
not_found unless %w{html css js}.include?(params[:section])
|
not_found unless %w{html css js}.include?(params[:section])
|
||||||
|
|
||||||
@section = params[:section]
|
@section = params[:section]
|
||||||
|
|
Loading…
Add table
Reference in a new issue