diff options
author | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2021-10-24 01:29:23 +0300 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2021-10-25 11:50:31 +0300 |
commit | 6a648a9ae96c5892a1285a96bb5d0f2bba842672 (patch) | |
tree | e983203943e4413dce2ea9fd2b74438794018323 /lib/Chat/ChatManager.php | |
parent | 93a62381aedc1b5d4d6cf807144d164b4cb90070 (diff) |
accept SHA256 hash sums for reference id as documented
- also use them for chat
- cf. https://github.com/nextcloud/spreed/blob/40caf331092c9dd5d23f1365d7fb4f0768d06b50/docs/chat.md
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
Diffstat (limited to 'lib/Chat/ChatManager.php')
-rw-r--r-- | lib/Chat/ChatManager.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/Chat/ChatManager.php b/lib/Chat/ChatManager.php index 4cbb60eb0..ec38cc887 100644 --- a/lib/Chat/ChatManager.php +++ b/lib/Chat/ChatManager.php @@ -133,7 +133,7 @@ class ChatManager { $comment->setMessage($message, self::MAX_CHAT_LENGTH); $comment->setCreationDateTime($creationDateTime); if ($referenceId !== null) { - $referenceId = trim(substr($referenceId, 0, 40)); + $referenceId = trim(substr($referenceId, 0, 64)); if ($referenceId !== '') { $comment->setReferenceId($referenceId); } @@ -220,7 +220,7 @@ class ChatManager { $comment->setParentId($replyTo->getId()); } - $referenceId = trim(substr($referenceId, 0, 40)); + $referenceId = trim(substr($referenceId, 0, 64)); if ($referenceId !== '') { $comment->setReferenceId($referenceId); } |