Fixed crashbug