template tag fix

This commit is contained in:
John Bintz 2010-02-22 20:33:46 -05:00
parent 744bcf4811
commit a3dc3e2174

View File

@ -57,7 +57,11 @@ function get_the_media_transcript($language = null) {
$transcripts = $approved_transcripts->get_transcripts(); $transcripts = $approved_transcripts->get_transcripts();
if (!empty($transcripts)) { if (!empty($transcripts)) {
if (isset($transcripts[$language])) { $transcript = $transcripts[$language]; } foreach ($transcripts as $transcript) {
if ($transcript['language'] == $language) {
return $transcript['transcript'];
}
}
} }
return $transcript; return $transcript;
} }