Merge branch 'master' into feature-statistics-icons

This commit is contained in:
savvasha
2018-05-15 17:12:56 +03:00
10 changed files with 54 additions and 14 deletions

View File

@@ -5,7 +5,7 @@
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Importers
* @version 2.6
* @version 2.6.3
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
@@ -123,9 +123,11 @@ if ( class_exists( 'WP_Importer' ) ) {
// Add team to player
add_post_meta( $id, 'sp_team', $team_id );
// Update current team if first in array
// Update current team if first in array, otherwise use as past team
if ( $i == 0 ):
update_post_meta( $id, 'sp_current_team', $team_id );
else :
add_post_meta( $id, 'sp_past_team', $team_id );
endif;
$i++;

View File

@@ -5,7 +5,7 @@
* @author ThemeBoy
* @category Admin
* @package SportsPress/Admin/Meta_Boxes
* @version 2.6
* @version 2.6.3
*/
if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly