microsoftgraph / microsoftgraph/msgraph-sdk-php
Deprecated nullable type causes a warning on PHP 8.4
まだ誰も着手していません。
- 主要言語
- PHP
- スター
- 669
- フォーク
- 150
- 平均マージ
- 15時間 21分
- マージ済み PR(30日)
- 3
説明
Describe the bug
This is a mostly self-explaining problem whose fix is, fortunately, very simple - literally one extra letter.
Deprecated: Microsoft\Graph\Core\Requests\BaseBatchRequestBuilder::__construct(): Implicitly marking parameter $errorMappings as nullable is deprecated, the explicit nullable type must be used instead in /var/www/html/vendor/microsoft/microsoft-graph-core/src/Requests/BaseBatchRequestBuilder.php on line 49
Looking at the signature of the constructor
public function __construct(RequestAdapter $requestAdapter, array $errorMappings = null)
should be
public function __construct(RequestAdapter $requestAdapter, ?array $errorMappings = null)
Maybe the whole codebase should be scanned for this deprecation... these will become errors in PHP 9.
Expected behavior
No deprecation warning.
How to reproduce
Run anything with this class under PHP 8.4
SDK Version
2.25.0
Latest version known to work for scenario above?
No response
Known Workarounds
No response
Debug output
Click to expand log
```</details>
### Configuration
_No response_
### Other information
_No response_
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
src/Requests/BaseBatchRequestBuilder.php の49行目付近から始め、レポートに示されているコンストラクターのシグネチャを確認してください。PHP 8.4 でクラスを実行し、非推奨警告を再現してください。コンストラクターがその警告を出力しなくなれば完了です。issue のコードベースに関するより広範な懸念に対処する場合に限り、他の nullable パラメーターも確認してください。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- php
- 領域
- api
- issue の種類
- バグ
- 難易度
- 1/5
- 見積もり時間
- 1時間未満
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 68/100