Swirrl/SemanticJournal

Should sanitize permalink before checking if it needs to be changed

Opened this issue · 1 comments

In Article#set_permalink, it seems that you should do Article.sanitize_permalink(new_permalink) before the check, so you can use the sanitized version to do the comparison, instead of checking, then sanitizing.

Unless I'm missing something...

You've got a point there. Although, set_permalink isn't called from anywhere (yet), so it's no biggy. Thanks though!