filter/mutate raise configError in register

As reported in LOGSTASH-2003, valid_types was an unknown local var and was raising an unexpected error.

This is fixed and now using the standard LogStash::ConfigurationError