improve settings parsing