Skip to content

Commit 844da3a

Browse files
committed
add compatibility with version 5.1.1
1 parent b03f732 commit 844da3a

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

IntegrationServices/PlatformVersionReader.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ public function __construct(PackageProvider $packageProvider)
3131
*/
3232
public function getIntegrationVersion()
3333
{
34-
return $this->packageProvider->getOroPackages()[$this->getIntegrationName()]->getFullPrettyVersion();
34+
$integrationDetails = $this->packageProvider->getOroPackages()[$this->getIntegrationName()];
35+
36+
return is_array($integrationDetails) ? $integrationDetails['pretty_version'] : $integrationDetails->getFullPrettyVersion();
3537
}
3638

3739
/**
@@ -48,7 +50,7 @@ public function getMolliePackageVersion()
4850
$molliePackage = $packageInterfaces['mollie/orocommerce'];
4951
}
5052

51-
return $molliePackage ? $molliePackage->getFullPrettyVersion() : null;
53+
return $molliePackage ? (is_array($molliePackage) ? $molliePackage['pretty_version'] : $molliePackage->getFullPrettyVersion()) : null;
5254
}
5355

5456
/**

0 commit comments

Comments
 (0)