calculating days active correctly