fix weird total bug