Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
R3
howto-cards
Commits
20ab0417
Verified
Commit
20ab0417
authored
Oct 28, 2019
by
Laurent Heirendt
✈
Browse files
catch for external cards accessed internally
parent
5270d409
Pipeline
#15756
passed with stage
in 1 minute and 28 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
.ci/.autoRedirect
View file @
20ab0417
...
...
@@ -27,8 +27,18 @@
if
(
status
===
200
){
// internal pages
if
(
sub
.
length
>
0
)
{
sub
=
'
internal/
'
+
sub
;
}
window
.
location
.
href
=
'
https://r3-core.pages.uni.lu/howto-cards-internal/stable/
'
+
sub
;
if
(
sub
.
length
>
0
)
{
UrlExists
(
'
https://r3-core.pages.uni.lu/howto-cards-internal/stable/internal/
'
+
sub
,
function
(
status
){
// redirect if card is actually internal and exists
if
(
status
==
200
)
{
window
.
location
.
href
=
'
https://r3-core.pages.uni.lu/howto-cards-internal/stable/internal/
'
+
sub
;
}
else
{
window
.
location
.
href
=
'
https://r3-core.pages.uni.lu/howto-cards-internal/stable/external/
'
+
sub
;
}
}
else
{
window
.
location
.
href
=
'
https://r3-core.pages.uni.lu/howto-cards-internal/stable/
'
+
sub
;
}
}
else
{
// external pages
if
(
sub
.
length
>
0
)
{
sub
=
'
external/
'
+
sub
;
}
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment