fix command ordering