finished fixing all bugs