File tree Expand file tree Collapse file tree 3 files changed +7
-10
lines changed Expand file tree Collapse file tree 3 files changed +7
-10
lines changed Original file line number Diff line number Diff line change @@ -4,8 +4,9 @@ All notable changes to this project will be documented in this file.
44## [ unreleased]
55
66* New aggregation pipeline builder by @GromNaN in [ #2738 ] ( https://github.com/mongodb/laravel-mongodb/pull/2738 )
7+ * Drop support for Composer 1.x by @GromNaN in [ #2784 ] ( https://github.com/mongodb/laravel-mongodb/pull/2784 )
78
8- ## [ 4.2.0] - 2024-12 -14
9+ ## [ 4.2.0] - 2024-03 -14
910
1011* Add support for Laravel 11 by @GromNaN in [ #2735 ] ( https://github.com/mongodb/laravel-mongodb/pull/2735 )
1112* Implement Model::createOrFirst() using findOneAndUpdate operation by @GromNaN in [ #2742 ] ( https://github.com/mongodb/laravel-mongodb/pull/2742 )
Original file line number Diff line number Diff line change 2424 "require" : {
2525 "php" : " ^8.1" ,
2626 "ext-mongodb" : " ^1.15" ,
27+ "composer-runtime-api" : " ^2.0.0" ,
2728 "illuminate/support" : " ^10.0|^11" ,
2829 "illuminate/container" : " ^10.0|^11" ,
2930 "illuminate/database" : " ^10.30|^11" ,
Original file line number Diff line number Diff line change 1616use MongoDB \Laravel \Concerns \ManagesTransactions ;
1717use Throwable ;
1818
19- use function class_exists ;
2019use function filter_var ;
2120use function implode ;
2221use function is_array ;
@@ -324,14 +323,10 @@ private static function getVersion(): string
324323
325324 private static function lookupVersion (): string
326325 {
327- if (class_exists (InstalledVersions::class)) {
328- try {
329- return self ::$ version = InstalledVersions::getPrettyVersion ('mongodb/laravel-mongodb ' );
330- } catch (Throwable ) {
331- return self ::$ version = 'error ' ;
332- }
326+ try {
327+ return self ::$ version = InstalledVersions::getPrettyVersion ('mongodb/laravel-mongodb ' ) ?? 'unknown ' ;
328+ } catch (Throwable ) {
329+ return self ::$ version = 'error ' ;
333330 }
334-
335- return self ::$ version = 'unknown ' ;
336331 }
337332}
You can’t perform that action at this time.
0 commit comments