Skip to content
This repository was archived by the owner on May 16, 2023. It is now read-only.

SlackAttachment.setTimestamp(Date date) throws NullPointerException #47

@bubu333gh

Description

@bubu333gh

Null-check is needed for the setter with Date param because mappers like Mapstruct are mapping null value to it. I had to make a workaround in my mapper like this:

@mapping(target = "timestamp", expression = "java(slackAttachment.getTimestamp() == null ? null : slackAttachment.getTimestamp().getTime() / 1000L)")

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions