- before_filter :authenticate_author!, :only => [:index, :show]
- before_filter :authenticate_admin!, :only => [:list, :browse]
+ if Manifest.manifest.magic_numbers['run_mode'] == 0
+ before_action :authenticate_user, :only => [:new, :edit, :create, :update, :destroy]
+ before_action :authenticate_author, :only => [:new, :edit, :create, :update, :destroy]
+ else
+ before_action :authenticate_reader, :only => [
+ :index, :show,
+ :by_author, :by_speech_balloon, :by_speech_balloon_template, :by_system_picture
+ ]
+ before_action :authenticate_user, :only => [:new, :edit, :create, :update, :destroy]
+ before_action :authenticate_author, :only => [:new, :edit, :create, :update, :destroy]
+ end