Skip to content

Commit

Permalink
Make return types less strict
Browse files Browse the repository at this point in the history
  • Loading branch information
Mosnar committed Nov 22, 2019
1 parent 9043018 commit 6356694
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
# Compress Changelog

## 1.0.2 - 2019-11-20
## 1.0.3 - 2019-11-22
### Fixed
- Improved compatibility with PHP 7.0.x (again-again)

## 1.0.2 - 2019-11-21
### Fixed
- Improved compatibility with PHP 7.0.x (again)

Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "venveo/craft-compress",
"description": "Create smart zip files from Craft assets on the fly",
"type": "craft-plugin",
"version": "1.0.2",
"version": "1.0.3",
"keywords": [
"craft",
"cms",
Expand Down
8 changes: 4 additions & 4 deletions src/services/Compress.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public function getArchiveModelForQuery($query, $lazy = false, $filename = null)
}
}

public function createArchiveRecord($assets, $archiveAsset = null): ArchiveRecord
public function createArchiveRecord($assets, $archiveAsset = null)
{
$archive = $this->createArchiveRecords($assets, $archiveAsset);
return $archive;
Expand Down Expand Up @@ -199,7 +199,7 @@ public function createArchiveAsset(ArchiveRecord $archiveRecord)
* @throws \yii\base\InvalidConfigException
* @throws \yii\db\Exception
*/
private function createArchiveRecords($zippedAssets, $asset, $archiveRecord = null): ArchiveRecord
private function createArchiveRecords($zippedAssets, $asset, $archiveRecord = null)
{
if (!$archiveRecord instanceof ArchiveRecord) {
$archiveRecord = new ArchiveRecord();
Expand Down Expand Up @@ -259,7 +259,7 @@ private function getHashForAssets($assets): string
* @param $hash
* @return ArchiveRecord|null
*/
private function getArchiveRecordByHash($hash): ArchiveRecord
private function getArchiveRecordByHash($hash)
{
return ArchiveRecord::findOne(['hash' => $hash]);
}
Expand All @@ -269,7 +269,7 @@ private function getArchiveRecordByHash($hash): ArchiveRecord
*
* @param Asset $asset
*/
public function handleAssetUpdated(Asset $asset): void
public function handleAssetUpdated(Asset $asset)
{
// Get the files this affects and the archives. We're just going to
// delete the asset for the archive to prompt it to regenerate.
Expand Down

0 comments on commit 6356694

Please sign in to comment.