Skip to content

Commit

Permalink
Fix up to: add canonical_url
Browse files Browse the repository at this point in the history
  • Loading branch information
leenagupte committed Sep 13, 2024
1 parent 1776bff commit db969d7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 0 additions & 4 deletions app/helpers/parts_navigation_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,4 @@ def part_link_elements(parts, current_part)
end
end
end

def canonical_url(part_path)
Plek.new.website_root + part_path
end
end
5 changes: 5 additions & 0 deletions app/helpers/url_helper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module UrlHelper do
def canonical_url(path)
Plek.new.website_root + path
end
end

Check failure on line 5 in app/helpers/url_helper.rb

View workflow job for this annotation

GitHub Actions / Lint Ruby / Run RuboCop

Lint/Syntax: unexpected token $end (Using Ruby 3.2 parser; configure using `TargetRubyVersion` parameter, under `AllCops`)

0 comments on commit db969d7

Please sign in to comment.