fix 'mode' option