Skip to content

Empty $data['subject'] [bug] #413

@CezaryGoralski

Description

@CezaryGoralski

Hello you have bug in triming notifications subjects at notifications/Push.php

if (strlen($subject) > $dataLength) {

if (strlen($subject) > $dataLength) { $data['subject'] = substr($subject, 0, $dataLength) . '…'; }

and it should be
if (strlen($subject) > $dataLength) { $data['subject'] = substr($subject, 0, $dataLength) . '…'; }else{ $data['subject'] = $notification->getParsedSubject(); }
because otherwise when the parsedSubject length will be less than 255 the $data['subject'] field is gona be empty

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions