1037 | | for module in templatetags_modules: |
1038 | | taglib_module = '%s.%s' % (module, library_name) |
1039 | | tried_modules.append(taglib_module) |
1040 | | lib = import_library(taglib_module) |
1041 | | if lib: |
1042 | | libraries[library_name] = lib |
1043 | | break |
| 1036 | # first try the fully qualified module path |
| 1037 | taglib_module = library_name |
| 1038 | tried_modules.append(taglib_module) |
| 1039 | lib = import_library(taglib_module) |
| 1040 | if lib: |
| 1041 | libraries[library_name] = lib |
| 1042 | else: # then search inside installed apps |
| 1043 | templatetags_modules = get_templatetags_modules() |
| 1044 | for module in templatetags_modules: |
| 1045 | taglib_module = '%s.%s' % (module, library_name) |
| 1046 | tried_modules.append(taglib_module) |
| 1047 | lib = import_library(taglib_module) |
| 1048 | if lib: |
| 1049 | libraries[library_name] = lib |
| 1050 | break |