Browse Source

Use the current forum version

Signed-off-by: Suki <[email protected]>
Suki 11 years ago
parent
commit
ee4f604683
2 changed files with 3 additions and 4 deletions
  1. 2 2
      Sources/Themes.php
  2. 1 2
      Themes/default/languages/Errors.english.php

+ 2 - 2
Sources/Themes.php

@@ -1500,14 +1500,14 @@ function ThemeInstall()
 
 			// Check for compatibility with 2.1 or greater.
 			if (!$theme_info_xml->exists('theme-info/install'))
-				fatal_lang_error('package_get_error_not_compatible');
+				fatal_lang_error('package_get_error_theme_not_compatible', false, $forum_version);
 
 			// So, we have an install tag which is cool and stuff but we also need to check it and match your current SMF version...
 			$the_version = strtr($forum_version, array('SMF ' => ''));
 			$install_versions = $theme_info_xml->path('theme-info/install/@for');
 
 			if (!$install_versions || !matchPackageVersion($the_version, $install_versions))
-				fatal_lang_error('package_get_error_not_compatible', false);
+				fatal_lang_error('package_get_error_theme_not_compatible', false, $forum_version);
 
 			$theme_info_xml = $theme_info_xml->path('theme-info[0]');
 			$theme_info_xml = $theme_info_xml->to_array();

+ 1 - 2
Themes/default/languages/Errors.english.php

@@ -300,8 +300,7 @@ $txt['package_get_error_is_zero'] = 'Although the package was downloaded to the
 $txt['package_get_error_packageinfo_corrupt'] = 'SMF was unable to find any valid information within the package-info.xml file included within the Package. There may be an error with the modification, or the package may be corrupt.';
 $txt['package_get_error_is_theme'] = 'You can\'t install a Theme from this section, please use the <a href="{MANAGETHEMEURL}">Themes and Layout</a> management page to upload it';
 $txt['package_get_error_is_mod'] = 'You can\'t install a mod from this section, please use the <a href="{MANAGEMODURL}">Package manager</a> page to upload it';
-$txt['package_get_error_not_compatible'] = 'Your theme does not show it has compatibility with SMF 2.1. Please contact the theme author.';
-
+$txt['package_get_error_theme_not_compatible'] = 'Your theme does not show it has compatibility with %1$s. Please contact the theme author.';
 $txt['no_membergroup_selected'] = 'No membergroup selected';
 $txt['membergroup_does_not_exist'] = 'The membergroup doesn\'t exist or is invalid.';