Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
WP Plugins
ETH Simple Shortlinks
Commits
f4818f69
Commit
f4818f69
authored
Mar 20, 2016
by
Erick Hitter
Browse files
Don't show on post status' that have no need for shortlinks
parent
68628e08
Changes
1
Hide whitespace changes
Inline
Side-by-side
eth-simple-shortlinks.php
View file @
f4818f69
...
@@ -123,6 +123,10 @@ class ETH_Simple_Shortlinks {
...
@@ -123,6 +123,10 @@ class ETH_Simple_Shortlinks {
return
$shortlink
;
return
$shortlink
;
}
}
if
(
!
in_array
(
get_post_status
(
$id
),
array
(
'publish'
,
'future'
)
)
)
{
return
$shortlink
;
}
return
user_trailingslashit
(
home_url
(
sprintf
(
'%s/%d'
,
$this
->
slug
,
$id
)
)
);
return
user_trailingslashit
(
home_url
(
sprintf
(
'%s/%d'
,
$this
->
slug
,
$id
)
)
);
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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