WordPress.org

Plugin Directory

Changeset 557225


Ignore:
Timestamp:
06/13/12 11:38:43 (23 months ago)
Author:
jorbin
Message:

don't display addthis_share if it's empty

File:
1 edited

Legend:

Unmodified
Added
Removed
  • addthis/trunk/addthis_social_widget.php

    r556734 r557225  
    14801480            $return .= 'if (typeof(addthis_share) == "undefined"){ addthis_share = ' . $options['addthis_share_json'] . ';}'; 
    14811481        else 
    1482             $return .= 'if (typeof(addthis_share) == "undefined"){ addthis_share = ' . json_encode( apply_filters('addthis_share_js_var', $addthis_share ) ) .';}'; 
    1483  
     1482        { 
     1483            $share = apply_filters('addthis_share_js_var', $addthis_share ); 
     1484            if (! empty($share) ) 
     1485                $return .= 'if (typeof(addthis_share) == "undefined"){ addthis_share = ' . json_encode( apply_filters('addthis_share_js_var', $addthis_share ) ) .';}'; 
     1486 
     1487        } 
    14841488        $return .= "\n"; 
    14851489 
Note: See TracChangeset for help on using the changeset viewer.