updated
[NOT WORKING] added some logic