How to change the role of the author of a node when this node is published?
The scenario is as follows:
The user has the role A, he posts a node, not published by default.
The node is published, the user obtains the role B.
I have tried to achieve this with Rules.
Event: after updating a node
But for condition and action, I tried different solutions for data picker (author): node.uid, node.uid.entity.uid.value, but there are errors “Expected a entity: user data type for context User but got …”
Do you know how to do this?