I have a global flag, spam
, that has a textfield, reason
, attached to it.
According to the Flag API documentation, I know I can check whether a user is flagged like this:
$spam && $spam->is_flagged($account->uid)
However, in this case, I want to retrieve the flagging, and then check the value of a field in that flagging. I didn't see any directions for doing so in the documentation, so I'm at a loss about how best to proceed.
$spam
? Hopefully it'sflag_entity
but maybe it'sflag_flag
?