From 97e657dab36c5b947d7913dfd48636ade5ab66d8 Mon Sep 17 00:00:00 2001 From: Rodrigo Souto Date: Mon, 8 Jun 2015 15:47:00 -0300 Subject: [PATCH] organizations: remove mistaken enabled? method --- app/models/profile.rb | 8 -------- test/functional/organizations_controller_test.rb | 6 +++--- 2 files changed, 3 insertions(+), 11 deletions(-) diff --git a/app/models/profile.rb b/app/models/profile.rb index 4c6f396..7c5a0e9 100644 --- a/app/models/profile.rb +++ b/app/models/profile.rb @@ -961,19 +961,11 @@ private :generate_url, :url_options self.save end - def disabled? - !visible - end - def enable self.visible = true self.save end - def enabled? - visible - end - def control_panel_settings_button {:title => _('Edit Profile'), :icon => 'edit-profile'} end diff --git a/test/functional/organizations_controller_test.rb b/test/functional/organizations_controller_test.rb index 928fe8b..09dafb2 100644 --- a/test/functional/organizations_controller_test.rb +++ b/test/functional/organizations_controller_test.rb @@ -91,17 +91,17 @@ class OrganizationsControllerTest < ActionController::TestCase get :activate, {:id => organization.id} organization.reload - assert organization.enabled? + assert organization.visible end should 'deactivate organization profile' do organization = fast_create(Organization, :visible => true, :environment_id => environment.id) - assert organization.enabled? + assert organization.visible get :deactivate, {:id => organization.id} organization.reload - assert organization.disabled? + assert !organization.visible end should 'destroy organization profile' do -- libgit2 0.21.2