ADDED SOME NEW CODE