Hello @edumusa ,
I have updated the plugin to import only updated episodes, I have extend the SSP importer function for it.
File:/seriously-simple-podcasting/php/classes/importers/class-rss-importer.php
In line 100:
public function import_rss_feed() {
….
….
replace count( $this->feed_object->channel->item );
with
$this->podcast_count = $this->feed_podcast_count();
}
public function feed_podcast_count() {
$podcast_count = count( $this->feed_object->channel->item ); // Get the count of podcast from feed
if ( ! empty( $this->series ) ) {
$previous_episodes = count(
get_posts(
[
‘post_type’ => $this->post_type,
‘post_status’ => ‘publish’,
‘fields’ => ‘ids’,
‘numberposts’ => -1,
‘tax_query’ => [
[
‘taxonomy’ => ‘series’,
‘field’ => ‘id’,
‘terms’ => $this->series,
‘include_children’ => false
]
]
]
)
); // Get the episodes count from DB.
if( !empty($previous_episodes) ){
if($previous_episodes < $podcast_count){
$podcast_count = $podcast_count – $previous_episodes;
} elseif($previous_episodes >= $podcast_count) {
$podcast_count = 0;
}
}
}
return $podcast_count;
}
@iviolini , @psykro Please take a look into it’s working for me if you wanna add these feature I can commit the code.