improved settings validation