Opened 5 years ago

Closed 5 years ago

Last modified 4 years ago

#30747 closed Cleanup/optimization (fixed)

Rename internal is_safe_url() to better state effective scope.

Reported by: Carlton Gibson Owned by: Carlton Gibson
Component: Utilities Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The name of the private django.utils.http.is_safe_url() suggests it does more than it really does.
Rename to url_has_allowed_host_and_scheme() to avoid possible confusion here.

Change History (5)

comment:1 by Carlton Gibson, 5 years ago

Has patch: set

comment:2 by Mariusz Felisiak, 5 years ago

Owner: changed from nobody to Carlton Gibson
Status: newassigned
Triage Stage: UnreviewedAccepted

comment:3 by Claude Paroz, 5 years ago

Thanks for the extra effort implementing the deprecation!

comment:4 by Mariusz Felisiak <felisiak.mariusz@…>, 5 years ago

Resolution: fixed
Status: assignedclosed

In 4f61810:

Fixed #30747 -- Renamed is_safe_url() to url_has_allowed_host_and_scheme().

comment:5 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

In 9e456f31:

Refs #30747 -- Removed django.utils.http.is_safe_url() per deprecation timeline.

Note: See TracTickets for help on using tickets.
Back to Top