Changeset 62325 for branches/7.0/src/wp-includes/l10n.php
- Timestamp:
- 05/07/2026 09:22:08 PM (2 months ago)
- Location:
- branches/7.0
- Files:
-
- 2 edited
-
. (modified) (1 prop)
-
src/wp-includes/l10n.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/7.0
-
branches/7.0/src/wp-includes/l10n.php
r62286 r62325 1207 1207 */ 1208 1208 function _load_script_textdomain_from_src( string $handle, string $src, string $domain, string $path, bool $is_module ) { 1209 /** @var WP_Textdomain_Registry $wp_textdomain_registry */ 1209 1210 global $wp_textdomain_registry; 1210 1211 … … 1215 1216 } 1216 1217 1217 $path = untrailingslashit( $path ); 1218 if ( $path ) { 1219 $path = untrailingslashit( $path ); 1220 } 1218 1221 1219 1222 // If a path was given and the handle file exists simply return it. … … 1232 1235 $languages_path = WP_LANG_DIR; 1233 1236 1234 $src_url = wp_parse_url( $src ); 1237 $src_url = wp_parse_url( $src ); 1238 if ( ! $src_url ) { 1239 return load_script_translations( false, $handle, $domain ); 1240 } 1241 $src_url['path'] ??= ''; 1242 1235 1243 $content_url = wp_parse_url( content_url() ); 1244 if ( ! $content_url ) { 1245 return load_script_translations( false, $handle, $domain ); 1246 } 1247 1236 1248 $plugins_url = wp_parse_url( plugins_url() ); 1237 1249 $site_url = wp_parse_url( site_url() ); … … 1305 1317 1306 1318 // If the source is not from WP. 1307 if ( false === $relative) {1319 if ( ! is_string( $relative ) ) { 1308 1320 return load_script_translations( false, $handle, $domain ); 1309 1321 }
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)