revamped - code, big changes!!