Added image_only flag to [activity] shortcode

This commit is contained in:
Justin Foell
2019-02-01 11:59:00 -06:00
parent 947b26faeb
commit 4f66886832
5 changed files with 62 additions and 43 deletions
+6 -1
View File
@@ -55,7 +55,12 @@ class WPStrava_RouteShortcode {
'markers' => false,
);
$atts = shortcode_atts( $defaults, $atts );
$atts = shortcode_atts( $defaults, $atts, 'route' );
/* Make sure boolean values are actually boolean
* @see https://wordpress.stackexchange.com/a/119299
*/
$atts['markers'] = filter_var( $atts['markers'], FILTER_VALIDATE_BOOLEAN );
$strava_som = WPStrava_SOM::get_som( $atts['som'] );
$route = WPStrava::get_instance()->routes;