Skip to content

Commit abc09f0

Browse files
committed
Fix insider only
1 parent 845f9a4 commit abc09f0

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

app/helpers/view_components/settings_nav.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,8 @@ def to_s
88
items = [
99
item_for("Account settings", :settings, :general),
1010
item_for("API / CLI", :api_cli_settings, :api_cli),
11-
item_for("Integrations", :integrations_settings, :integrations)
12-
]
13-
items << item_for("GitHub Syncer", :settings_github_syncer, :github_syncer) if current_user.insider?
14-
items += [
11+
item_for("Integrations", :integrations_settings, :integrations),
12+
item_for("GitHub Syncer", :settings_github_syncer, :github_syncer),
1513
item_for("Preferences", :user_preferences_settings, :preferences),
1614
item_for("Communication Preferences", :communication_preferences_settings, :communication),
1715
item_for("Donations", :donations_settings, :donations),
@@ -24,7 +22,7 @@ def to_s
2422
end
2523

2624
def item_for(text, route, key)
27-
return if key == :github_syncer && !current_user.admin?
25+
return if key == :github_syncer && !current_user.insider?
2826

2927
tag.li do
3028
key == selected ?

app/views/settings/github_syncer/show.html.haml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
.lg-container
33
= render ViewComponents::SettingsNav.new(:github_syncer)
44

5-
- if current_user.admin?
5+
- if current_user.insider?
66
%article
77
- if current_user.github_solution_syncer
88
%h1 GitHub Syncer

0 commit comments

Comments
 (0)