|
@@ 205-215 (lines=11) @@
|
| 202 |
|
$feed_name = $object->feed; |
| 203 |
|
} |
| 204 |
|
return $this->get_object( $feed_name, 'feed', $object ); |
| 205 |
|
} elseif ( $object instanceof \WP_Post ) { |
| 206 |
|
$calendar = $this->get_calendar( $object ); |
| 207 |
|
|
| 208 |
|
if ( isset( $calendar->feed ) ) { |
| 209 |
|
return $this->get_object( $calendar->feed, 'feed', $calendar ); |
| 210 |
|
} else { |
| 211 |
|
return null; |
| 212 |
|
} |
| 213 |
|
|
| 214 |
|
|
| 215 |
|
} elseif ( isset( $object->feed ) && isset( $object->id ) ) { |
| 216 |
|
return $this->get_object( $object->feed, 'feed', $object ); |
| 217 |
|
} |
| 218 |
|
} |
|
@@ 220-223 (lines=4) @@
|
| 217 |
|
} |
| 218 |
|
} |
| 219 |
|
|
| 220 |
|
if ( is_int( $object ) ) { |
| 221 |
|
$calendar = $this->get_calendar( $object ); |
| 222 |
|
return isset( $calendar->feed ) ? $this->get_object( $calendar->feed, 'feed', $calendar ) : null; |
| 223 |
|
} |
| 224 |
|
|
| 225 |
|
return null; |
| 226 |
|
} |