Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-06-03 15:01:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-06-03 15:01:18 +0400
commit9238d6f71bf05e9676b6a37198d719c3f803ab04 (patch)
tree8f572b604b79b2a663f06bc175e4c4eb35e36db9 /release/scripts
parent20e49e7177cbc10e3a4b45e6c32d5a3e447a935b (diff)
use fnmatch for reference globing rather then regex - regex overly complicates simple cases and wasnt being taken advantage of.
Diffstat (limited to 'release/scripts')
-rw-r--r--release/scripts/startup/bl_operators/wm.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/release/scripts/startup/bl_operators/wm.py b/release/scripts/startup/bl_operators/wm.py
index 2d8d1a59693..4d95c2d5d03 100644
--- a/release/scripts/startup/bl_operators/wm.py
+++ b/release/scripts/startup/bl_operators/wm.py
@@ -845,11 +845,11 @@ class WM_OT_doc_view_manual(Operator):
@staticmethod
def _find_reference(rna_id, url_mapping):
- print("online manual check for: '%s' ... " % rna_id, end="")
- from re import match
+ print("online manual check for: '%s'... " % rna_id)
+ from fnmatch import fnmatch
for pattern, url_suffix in url_mapping:
- if match(pattern, rna_id):
- print("match found:", pattern)
+ if fnmatch(rna_id, pattern):
+ print(" match found: '%s' --> '%s'" % (pattern, url_suffix))
return url_suffix
print("match not found")
return None