Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Mastodon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TeDomum
Mastodon
Commits
48ee3ae1
Unverified
Commit
48ee3ae1
authored
1 year ago
by
Claire
Committed by
GitHub
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
Merge pull request from GHSA-v3xf-c9qf-j667
parent
5f9511c3
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/lib/tag_manager.rb
+3
-3
3 additions, 3 deletions
app/lib/tag_manager.rb
with
3 additions
and
3 deletions
app/lib/tag_manager.rb
+
3
−
3
View file @
48ee3ae1
...
...
@@ -7,18 +7,18 @@ class TagManager
include
RoutingHelper
def
web_domain?
(
domain
)
domain
.
nil?
||
domain
.
gsub
(
/[\/]/
,
'
'
).
casecmp
(
Rails
.
configuration
.
x
.
web_domain
).
zero?
domain
.
nil?
||
domain
.
delete_suffix
(
'/
'
).
casecmp
(
Rails
.
configuration
.
x
.
web_domain
).
zero?
end
def
local_domain?
(
domain
)
domain
.
nil?
||
domain
.
gsub
(
/[\/]/
,
'
'
).
casecmp
(
Rails
.
configuration
.
x
.
local_domain
).
zero?
domain
.
nil?
||
domain
.
delete_suffix
(
'/
'
).
casecmp
(
Rails
.
configuration
.
x
.
local_domain
).
zero?
end
def
normalize_domain
(
domain
)
return
if
domain
.
nil?
uri
=
Addressable
::
URI
.
new
uri
.
host
=
domain
.
gsub
(
/[\/]/
,
'
'
)
uri
.
host
=
domain
.
delete_suffix
(
'/
'
)
uri
.
normalized_host
end
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment