fixed bug where value was not kept from initial DOM