-
-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
26 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,7 +7,7 @@ | |
* @wordpress-plugin | ||
* | ||
* Plugin Name: Multisite Language Switcher | ||
* Version: 2.6.4 | ||
* Version: 2.7.0 | ||
* Plugin URI: http://msls.co/ | ||
* Description: A simple but powerful plugin that will help you to manage the relations of your contents in a multilingual multisite-installation. | ||
* Author: Dennis Ploetner | ||
|
@@ -30,7 +30,7 @@ | |
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | ||
*/ | ||
|
||
if ( file_exists(__DIR__ . '/vendor/autoload.php' ) ) { | ||
if ( file_exists( __DIR__ . '/vendor/autoload.php' ) ) { | ||
require __DIR__ . '/vendor/autoload.php'; | ||
} | ||
|
||
|
@@ -40,7 +40,7 @@ | |
* @author Dennis Ploetner <[email protected]> | ||
*/ | ||
if ( ! defined( 'MSLS_PLUGIN_VERSION' ) ) { | ||
define( 'MSLS_PLUGIN_VERSION', '2.6.4' ); | ||
define( 'MSLS_PLUGIN_VERSION', '2.7.0' ); | ||
define( 'MSLS_PLUGIN_PATH', plugin_basename( __FILE__ ) ); | ||
define( 'MSLS_PLUGIN__FILE__', __FILE__ ); | ||
|
||
|
@@ -54,7 +54,7 @@ | |
* @return string | ||
*/ | ||
function get_the_msls( $attr ): string { | ||
$arr = is_array( $attr ) ? $attr : []; | ||
$arr = is_array( $attr ) ? $attr : array(); | ||
$obj = apply_filters( 'msls_get_output', null ); | ||
|
||
return ! is_null( $obj ) ? strval( $obj->set_tags( $arr ) ) : ''; | ||
|
@@ -77,7 +77,7 @@ function get_the_msls( $attr ): string { | |
* | ||
* @param string[] $arr | ||
*/ | ||
function the_msls( array $arr = [] ): void { | ||
function the_msls( array $arr = array() ): void { | ||
echo get_the_msls( $arr ); | ||
} | ||
|
||
|
@@ -89,7 +89,7 @@ function the_msls( array $arr = [] ): void { | |
* @return string | ||
*/ | ||
function get_msls_flag_url( string $locale ): string { | ||
return ( new \lloc\Msls\MslsOptions )->get_flag_url( $locale ); | ||
return ( new \lloc\Msls\MslsOptions() )->get_flag_url( $locale ); | ||
} | ||
|
||
/** | ||
|
@@ -126,8 +126,8 @@ function get_msls_permalink( string $locale, string $default = '' ): string { | |
} | ||
|
||
/** | ||
* Looks for the MslsBlog instance for a specific locale | ||
* | ||
* Looks for the MslsBlog instance for a specific locale | ||
* | ||
* @param string $locale | ||
* | ||
* @return \lloc\Msls\MslsBlog|null | ||
|
@@ -145,14 +145,14 @@ function msls_blog_collection(): \lloc\Msls\MslsBlogCollection { | |
return \lloc\Msls\MslsBlogCollection::instance(); | ||
} | ||
|
||
/** | ||
* Gets the MslsOptions instance | ||
* | ||
* @return \lloc\Msls\MslsOptions | ||
*/ | ||
function msls_options(): \lloc\Msls\MslsOptions { | ||
return \lloc\Msls\MslsOptions::instance(); | ||
} | ||
/** | ||
* Gets the MslsOptions instance | ||
* | ||
* @return \lloc\Msls\MslsOptions | ||
*/ | ||
function msls_options(): \lloc\Msls\MslsOptions { | ||
return \lloc\Msls\MslsOptions::instance(); | ||
} | ||
|
||
lloc\Msls\MslsPlugin::init(); | ||
lloc\Msls\MslsPlugin::init(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters