added alot of functionalities