Strip trailing '.' in canonical_url()