Fix cropping of space banner (#5964)

This commit is contained in:
Yuriy Bakhtin 2022-12-02 13:28:33 +04:00 committed by GitHub
parent 2d1e4a8912
commit 4dd5826890
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 0 deletions

View File

@ -4,6 +4,7 @@ HumHub Changelog
1.12.3 (Unreleased)
-------------------
- Fix #5928: Invalid Mailer DSN breaks whole application
- Fix #5960: Fix cropping of space banner
1.12.2 (November 11, 2022)
--------------------------

View File

@ -118,4 +118,21 @@ class CropProfileImage extends Model
];
}
/**
* @inheritdoc
*/
public function load($data, $formName = null)
{
if (parent::load($data, $formName)) {
// Make sure the params are integer formatted
$this->cropX = intval($this->cropX);
$this->cropY = intval($this->cropY);
$this->cropW = intval($this->cropW);
$this->cropH = intval($this->cropH);
return true;
}
return false;
}
}