added some improvements and features