diff --git a/h5p.classes.php b/h5p.classes.php index 4a386a7..51ffcec 100644 --- a/h5p.classes.php +++ b/h5p.classes.php @@ -1251,7 +1251,9 @@ Class H5PExport { // Build h5p.json $h5pJson = array ( 'title' => $content['title'], - 'language' => $content['language'], + // TODO - stop using 'und', this is not the preferred way. + // Either remove language from the json if not existing, or use "language": null + 'language' => isset($content['language']) ? $content['language'] : 'und', 'mainLibrary' => $content['library']['name'], 'embedTypes' => $embedTypes, );