aboutsummaryrefslogtreecommitdiff
path: root/classes/TidypicsImage.php
diff options
context:
space:
mode:
Diffstat (limited to 'classes/TidypicsImage.php')
-rw-r--r--classes/TidypicsImage.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/classes/TidypicsImage.php b/classes/TidypicsImage.php
index c0b5de723..dd4324468 100644
--- a/classes/TidypicsImage.php
+++ b/classes/TidypicsImage.php
@@ -244,6 +244,11 @@ class TidypicsImage extends ElggFile {
trigger_error('Tidypics warning: image memory size too large for resizing so rejecting', E_USER_WARNING);
throw new Exception(elgg_echo('tidypics:image_pixels'));
}
+
+ // make sure file fits quota
+ if (!tp_upload_check_quota($data['size'], elgg_get_logged_in_user_guid())) {
+ throw new Exception(elgg_echo('tidypics:cannot_upload_exceeds_quota'));
+ }
}
/**