Browse Source

Merge pull request #35139 from nextcloud/revert-35015-patch-1

Revert "Appropriate length check in Notification.php"
tags/v26.0.0beta1
Joas Schilling 1 year ago
parent
commit
ea377578ad
No account linked to committer's email address
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      lib/private/Notification/Notification.php

+ 2
- 2
lib/private/Notification/Notification.php View File

@@ -197,12 +197,12 @@ class Notification implements INotification {
* @since 8.2.0 - 9.0.0: Type of $id changed to string
*/
public function setObject(string $type, string $id): INotification {
if ($type === '' || mb_strlen($type) > 64) {
if ($type === '' || isset($type[64])) {
throw new \InvalidArgumentException('The given object type is invalid');
}
$this->objectType = $type;

if ($id === '' || mb_strlen($id) > 64) {
if ($id === '' || isset($id[64])) {
throw new \InvalidArgumentException('The given object id is invalid');
}
$this->objectId = $id;

Loading…
Cancel
Save