Sha256: fcfcba7002ff5fee3a897adcd5f2028bad49a1c6ce22f432f893b4bf48dd8853
Contents?: true
Size: 710 Bytes
Versions: 19
Compression:
Stored size: 710 Bytes
Contents
class Spud::SetupController < Spud::ApplicationController layout 'spud/setup' def index @page_thumbnail = "spud/admin/users_thumb.png" @page_name = "First Time Setup" if SpudUser.count != 0 flash[:error] = "Access Denied! This wizard may only be executed when the database is empty." redirect_to root_url() and return end if request.post? @user = SpudUser.new(:login => params[:login],:email => params[:email],:password => params[:password],:password_confirmation => params[:password_confirmation]) @user.super_admin = true if @user.save redirect_to spud_admin_root_url() and return end flash[:error] = "Error creating administrative account!" else end end end
Version data entries
19 entries across 19 versions & 2 rubygems