added logic
added logic