fix table resetting