Skip to content

Commit cf3b0e2

Browse files
committed
do not cache action_symbol - fixes #7815
we change the action param for wikis if it's fresh. So if we cache the symbol we end up with inconsistent action_symbol and action_string. We also end up with the show tab being active despite edit being rendered.
1 parent afcd53c commit cf3b0e2

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

app/controllers/common/application/url_identifiers.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ def action_string
153153
end
154154

155155
def action_symbol
156-
@action_symbol ||= if params[:action].present?
156+
if params[:action].present?
157157
params[:action].to_sym
158158
else
159159
nil

extensions/pages/wiki_page/test/integration/wiki_test.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def setup
1212
end
1313

1414
def test_writing_initial_version
15-
# assert_page_tab "Edit"
15+
assert_page_tab "Edit"
1616
content = update_wiki
1717
assert_content content
1818
assert_page_tab "Show"

0 commit comments

Comments
 (0)