Commit f4818f69 authored by Erick Hitter's avatar Erick Hitter

Don't show on post status' that have no need for shortlinks

parent 68628e08
......@@ -123,6 +123,10 @@ class ETH_Simple_Shortlinks {
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 ) ) );
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment