Fix a regression in notifier service which would cause generic trigger to only be dispatched on completed states, but not on custom states if action_sensor.emit_when config option was configured.
Fix a regression in notifier service which would cause generic trigger
to only be dispatched on completed states, but not on custom states if
action_sensor.emit_when config option was configured.

Issue was inadverently introduced in
https://github.com/StackStorm/st2/pull/4536,

Issue reported by Hiroyasu OHYAMA (@userlocalhost).

StackStorm/st2,StackStorm/st2,nzlosh/st2,nzlosh/st2,Plexxi/st2,Plexxi/st2,nzlosh/st2,Plexxi/st2,StackStorm/st2,nzlosh/st2,Plexxi/st2,StackStorm/st2