Corrected login check on content pages concerning permalinks