bugfix: potential segfault during startup on invalid config

could happen if invalid actions were present, which could lead
to improper handling in optimizer.