diff --git a/h5p-development.class.php b/h5p-development.class.php
index <HASH>..<HASH> 100644
--- a/h5p-development.class.php
+++ b/h5p-development.class.php
@@ -94,6 +94,9 @@ class H5PDevelopment {
       // Save/update library.
       $this->h5pF->saveLibraryData($library, $library['libraryId'] === FALSE);
 
+      // Need to decode it again, since it is served from here.
+      $library['metadataSettings'] = json_decode($library['metadataSettings']);
+
       $library['path'] = 'development/' . $contents[$i];
       $this->libraries[H5PDevelopment::libraryToString($library['machineName'], $library['majorVersion'], $library['minorVersion'])] = $library;
     }
metadataSettings returned as JSON, not string