Fix some issues and add fix command.