small bugfix and some error checking in dns_manager web API module