Skip to content
This repository was archived by the owner on Dec 12, 2021. It is now read-only.
This repository was archived by the owner on Dec 12, 2021. It is now read-only.

Different exception messages for same pair of actions and subject #1047

@bestiara

Description

@bestiara

Hi. After reading the wiki, I realized that I can assign custom error messages for different pairs of actions and subject. But how can I assign different messages for same pairs, but for different conditions of access dening? Like here:

cannot :manage, [Document, Plan] unless user.have_access?
cannot :manage, [Document, Plan] unless user.ready_for_work?

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