Updated according to review comments