fixed all bugs!