Plugin Directory

Changeset 588159


Ignore:
Timestamp:
08/21/2012 04:10:33 AM (14 years ago)
Author:
Captin Shmit
Message:

Fixed WP_DEBUG errors that appear when site has no podcast episodes

Location:
message-flow
Files:
1 added
2 edited
10 copied

Legend:

Unmodified
Added
Removed
  • message-flow/tags/1.1.2/trunk/main.php

    r588156 r588159  
    44Plugin URI: http://JoeAnzalone.com/plugins/message-flow
    55Description: Provides a shortcode that generates a cover flow-like interface for all podcasts in a given category or feed: [message-flow category="11"]
    6 Version: 1.1.1
     6Version: 1.1.2
    77Author: Joe Anzalone
    88Author URI: http://JoeAnzalone.com
     
    104104            <div class="flow">';
    105105   
     106        if(empty($posts_array)){
     107            return NULL;
     108        }
    106109        foreach($posts_array as $post){
    107110            if(empty($post->from_external_feed)){
     
    110113            $enclosure = get_post_meta($post->ID, 'enclosure', TRUE);
    111114            if(!empty($post->podcast_episode_url) OR (!$post->from_external_feed && !empty($enclosure))){
    112                 $podcast_episode_text_content = $post->post_content;
     115                if(!empty($post->post_content)){
     116                    $podcast_episode_text_content = $post->post_content;
     117                }
    113118               
    114119                if(!empty($post->podcast_episode_url)){
     
    151156                </div>';
    152157               
    153                 $podcast_episodes_text_contents[$post->ID] = $podcast_episode_text_content;
     158                if(!empty($podcast_episode_text_content)){
     159                    $podcast_episodes_text_contents[$post->ID] = $podcast_episode_text_content;
     160                }               
    154161            }
    155162        }
     
    179186       
    180187        $html .= '<div class="current podcast-episode-text-content">';
    181         $html .= $podcast_episode_text_content;
     188       
     189        if(!empty($podcast_episode_text_content)){
     190            $html .= $podcast_episode_text_content;
     191        }
    182192       
    183193        $html .= '</div>';
  • message-flow/tags/1.1.2/trunk/readme.txt

    r588156 r588159  
    1717
    1818= Usage =
    19 Show the ten latest podcast episodes
     19Show the ten latest podcast episodes:
    2020`[message-flow]`
    2121
     
    4444== Changelog ==
    4545
     46= 1.1.2 =
     47* Fixed WP_DEBUG errors that appear when site has no podcast episodes
     48
    4649= 1.1.1 =
    4750* Fixed WP_DEBUG errors
  • message-flow/trunk/main.php

    r588156 r588159  
    44Plugin URI: http://JoeAnzalone.com/plugins/message-flow
    55Description: Provides a shortcode that generates a cover flow-like interface for all podcasts in a given category or feed: [message-flow category="11"]
    6 Version: 1.1.1
     6Version: 1.1.2
    77Author: Joe Anzalone
    88Author URI: http://JoeAnzalone.com
     
    104104            <div class="flow">';
    105105   
     106        if(empty($posts_array)){
     107            return NULL;
     108        }
    106109        foreach($posts_array as $post){
    107110            if(empty($post->from_external_feed)){
     
    110113            $enclosure = get_post_meta($post->ID, 'enclosure', TRUE);
    111114            if(!empty($post->podcast_episode_url) OR (!$post->from_external_feed && !empty($enclosure))){
    112                 $podcast_episode_text_content = $post->post_content;
     115                if(!empty($post->post_content)){
     116                    $podcast_episode_text_content = $post->post_content;
     117                }
    113118               
    114119                if(!empty($post->podcast_episode_url)){
     
    151156                </div>';
    152157               
    153                 $podcast_episodes_text_contents[$post->ID] = $podcast_episode_text_content;
     158                if(!empty($podcast_episode_text_content)){
     159                    $podcast_episodes_text_contents[$post->ID] = $podcast_episode_text_content;
     160                }               
    154161            }
    155162        }
     
    179186       
    180187        $html .= '<div class="current podcast-episode-text-content">';
    181         $html .= $podcast_episode_text_content;
     188       
     189        if(!empty($podcast_episode_text_content)){
     190            $html .= $podcast_episode_text_content;
     191        }
    182192       
    183193        $html .= '</div>';
  • message-flow/trunk/readme.txt

    r588156 r588159  
    1717
    1818= Usage =
    19 Show the ten latest podcast episodes
     19Show the ten latest podcast episodes:
    2020`[message-flow]`
    2121
     
    4444== Changelog ==
    4545
     46= 1.1.2 =
     47* Fixed WP_DEBUG errors that appear when site has no podcast episodes
     48
    4649= 1.1.1 =
    4750* Fixed WP_DEBUG errors
Note: See TracChangeset for help on using the changeset viewer.