mirror of
https://github.com/neocities/neocities.git
synced 2025-08-05 17:18:02 +02:00
fixes and cleanups for new auth model
This commit is contained in:
parent
21b0848030
commit
f44ce014d3
8 changed files with 63 additions and 32 deletions
2
app.rb
2
app.rb
|
@ -557,6 +557,8 @@ end
|
|||
def require_ownership_for_settings
|
||||
@site = Site[username: params[:username]]
|
||||
|
||||
not_found if @site.nil?
|
||||
|
||||
unless @site.owned_by? parent_site
|
||||
flash[:error] = 'Cannot edit this site, you do not have permission.'
|
||||
redirect request.referrer
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue