fix returning blank permalinks