adding old code for speedy implementation later