diff options
| author | Chris Beaven <smileychris@gmail.com> | 2010-11-26 02:28:07 +0000 |
|---|---|---|
| committer | Chris Beaven <smileychris@gmail.com> | 2010-11-26 02:28:07 +0000 |
| commit | aff9ff9bf52c71790cd1f37eb0f6a426b98e8338 (patch) | |
| tree | 2ffae0cc2d7c5cf8d36d8a3d01cfd9a1bd4fbc7a | |
| parent | 188324881c0acdba74d50d26ab672a5cfcb4e983 (diff) | |
Fixes #14715 -- More informative ValueError for safe_join util. Thanks btubbs.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@14699 bcc190cf-cafb-0310-a4f2-bffc1f526a37
| -rw-r--r-- | django/utils/_os.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/utils/_os.py b/django/utils/_os.py index d75714bce1..7ec5ce114b 100644 --- a/django/utils/_os.py +++ b/django/utils/_os.py @@ -41,6 +41,6 @@ def safe_join(base, *paths): # equal to base_path). if not final_path.startswith(base_path) \ or final_path[base_path_len:base_path_len+1] not in ('', sep): - raise ValueError('the joined path is located outside of the base path' - ' component') + raise ValueError('The joined path (%s) is located outside of the base ' + 'path component (%s)' % (final_path, base_path)) return final_path |
