Why: - ParsoidRenderID::newFromKey() validates incoming keys and throws an InvalidArgumentException if a required key component was missing. - It does so by eagerly destructuring the return value of explode(), which causes a PHP Notice for invalid inputs as the expected offsets won't exist then. What: - Check the count of key parts before destructuring. - Add unit tests. Bug: T385567 Change-Id: I1d936ae038f85ffa2e5d1d3d8a75fdc75e4c8ef8 (cherry picked from commit eec130925c081c2da1c475f9a9ce719e6838ca51) |
||
|---|---|---|
| .. | ||
| ParsoidOutputStash.php | ||
| ParsoidRenderID.php | ||
| PreparedEdit.php | ||
| SelserContext.php | ||
| SimpleParsoidOutputStash.php | ||