even better fix to #1054