diff --git a/src/apis/StorageController.php b/src/apis/StorageController.php
index 9705dbf15..83987be31 100644
--- a/src/apis/StorageController.php
+++ b/src/apis/StorageController.php
@@ -253,6 +253,10 @@ public function actionImageInfo($id)
throw new NotFoundHttpException("Unable to find the given storage image.");
}
+ if (!$model->file->isImage) {
+ return $model->toArray(['id', 'source', 'file_id', 'filter_id', 'resolution_width', 'resolution_height', 'file'], ['source']);
+ }
+
// try to create thumbnail on view if not done
if (empty($model->tinyCropImage)) {
// there are very rare cases where the thumbnail does not exists, therefore generate the thumbnail and reload the model.
diff --git a/src/views/layouts/_angulardirectives.php b/src/views/layouts/_angulardirectives.php
index 74522a81b..0a6e2b6f0 100644
--- a/src/views/layouts/_angulardirectives.php
+++ b/src/views/layouts/_angulardirectives.php
@@ -167,7 +167,7 @@
-
+
{{ imageinfo.resolution_width }} x {{ imageinfo.resolution_height }}