Fixing permalink not working on activation

@randybuildsthings , won't you merge my code? :)