I think this is the right way
updated comments