Fix issue with direct links returning as fragments