Updated schema validation

format function can now access the whole config instance, not only the current value