Skip to content

Commit 2e2dad2

Browse files
committed
Delete beta access
1 parent 364b24f commit 2e2dad2

File tree

8 files changed

+8
-36
lines changed

8 files changed

+8
-36
lines changed

app/controllers/application_controller.rb

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -201,10 +201,6 @@ def is_admin?
201201
signed_in? && current_user.admin?
202202
end
203203

204-
def require_beta_access!
205-
return head(:forbidden) unless signed_in? && current_user.has_beta_access?
206-
end
207-
208204
def iphone_user_agent?
209205
request.env["HTTP_USER_AGENT"] && request.env["HTTP_USER_AGENT"][/(Mobile\/.+Safari)/]
210206
end

app/controllers/users_controller.rb

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,12 +66,6 @@ def index
6666
end
6767
end
6868

69-
def beta
70-
return head(:forbidden) unless signed_in? && (current_user.beta_access? || current_user.admin?)
71-
@user = current_user
72-
@users = User.where('banner is not null')
73-
end
74-
7569
def create
7670
@user = User.for_omniauth(oauth)
7771
Rails.logger.debug("Creating User: #{@user.inspect}") if ENV['DEBUG']

app/models/user.rb

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -446,10 +446,6 @@ def total_achievements
446446
badges_count
447447
end
448448

449-
def has_beta_access?
450-
admin? || beta_access
451-
end
452-
453449
def award(badge)
454450
new_badge = self.badges.of_type(badge).first || self.badges.build(badge_class_name: badge.class.name)
455451
end
@@ -1366,7 +1362,6 @@ def manage_github_orgs
13661362
# linkedin_secret :string(255)
13671363
# last_email_sent :datetime
13681364
# linkedin_public_url :string(255)
1369-
# beta_access :boolean default(FALSE)
13701365
# redemptions :text
13711366
# endorsements_count :integer default(0)
13721367
# team_document_id :string(255) indexed

app/views/users/beta.html.haml

Lines changed: 0 additions & 17 deletions
This file was deleted.

config/initializers/airbrake.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,7 @@
66
config.secure = config.port == 443
77
end
88
else
9-
Rails.logger.warn '[WTF WARNING] Someone deleted airbrake and forgot the initializer'
9+
unless Rails.env.test? || Rails.env.development?
10+
Rails.logger.warn '[WTF WARNING] Someone deleted airbrake and forgot the initializer'
11+
end
1012
end

config/routes.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,6 @@
247247
# PUT /users/:id(.:format) users#update
248248
# DELETE /users/:id(.:format) users#destroy
249249
# clear_provider GET /clear/:id/:provider(.:format) users#clear_provider
250-
# visual GET /visual(.:format) users#beta
251250
# refresh GET /refresh/:username(.:format) users#refresh
252251
# random_accomplishment GET /nextaccomplishment(.:format) highlights#random
253252
# add_skill GET /add-skill(.:format) skills#create
@@ -467,7 +466,6 @@
467466
end
468467

469468
get '/clear/:id/:provider' => 'users#clear_provider', as: :clear_provider
470-
get '/visual' => 'users#beta'
471469
get '/refresh/:username' => 'users#refresh', as: :refresh
472470
get '/nextaccomplishment' => 'highlights#random', as: :random_accomplishment
473471
get '/add-skill' => 'skills#create', as: :add_skill, :via => :post
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
class RemoveBetaAccess < ActiveRecord::Migration
2+
def up
3+
remove_column :users, :beta_access
4+
end
5+
end

spec/fabricators/user_fabricator.rb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@
7474
# linkedin_secret :string(255)
7575
# last_email_sent :datetime
7676
# linkedin_public_url :string(255)
77-
# beta_access :boolean default(FALSE)
7877
# redemptions :text
7978
# endorsements_count :integer default(0)
8079
# team_document_id :string(255) indexed

0 commit comments

Comments
 (0)