Fix custom effect type sometimes incorrect.

Fixes #336
2 jobs for release/22.04 in 6 minutes and 51 seconds (queued for 1 minute and 5 seconds)