Skip to content

Commit d81631b

Browse files
Fixed : System Generated URL not working
1 parent 2c53d82 commit d81631b

File tree

3 files changed

+5
-9
lines changed

3 files changed

+5
-9
lines changed

dist/index.js

Lines changed: 2 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/helpers.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,7 @@ module.exports = {
1313
a: atag,
1414
img: imgtag,
1515
post_link: function( post, username, BLOG_URL = false ) {
16-
if( false !== BLOG_URL ) {
17-
return `${BLOG_URL}/${post.slug}`;
18-
}
19-
return `https://${username}.hashnode.dev/${post.slug}-${post.cuid}`;
16+
return ( '' !== BLOG_URL ) ? `${BLOG_URL}/${post.slug}` : `https://${username}.hashnode.dev/${post.slug}-${post.cuid}`;
2017
},
2118
image_size: function( user_value, _default, small, large ) {
2219
if( 'small' === user_value ) {
@@ -33,3 +30,4 @@ module.exports = {
3330
return user_value;
3431
}
3532
};
33+

0 commit comments

Comments
 (0)