Skip to content
This repository was archived by the owner on Jun 9, 2023. It is now read-only.

Commit 2e14839

Browse files
committed
Added single item retrieval from the show section class.
1 parent d216734 commit 2e14839

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

Server/Library/Section/Show.php

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,4 +292,36 @@ public function searchEpisodes($query)
292292
)
293293
);
294294
}
295+
296+
/**
297+
* Returns a single show by its rating key, key, or exact title match.
298+
*
299+
* @param integer|string $polymorphicData Either a rating key, a key, or a
300+
* title for an exact title match that will be used to retrieve a single
301+
* show.
302+
*
303+
* @uses Plex_Server_Library_SectionAbstract::getPolymorphicItem()
304+
*
305+
* @retrun Plex_Server_Library_Item_Show A Plex library show object.
306+
*/
307+
public function getShow($polymorphicData)
308+
{
309+
return $this->getPolymorphicItem($polymorphicData);
310+
}
311+
312+
/**
313+
* Returns a single episode by its rating key, key, or exact title match.
314+
*
315+
* @param integer|string $polymorphicData Either a rating key, a key, or a
316+
* title for an exact title match that will be used to retrieve a single
317+
* episode.
318+
*
319+
* @uses Plex_Server_Library_SectionAbstract::getPolymorphicItem()
320+
*
321+
* @retrun Plex_Server_Library_Item_Episode A Plex library episode object.
322+
*/
323+
public function getEpisode($polymorphicData)
324+
{
325+
return $this->getPolymorphicItem($polymorphicData);
326+
}
295327
}

0 commit comments

Comments
 (0)