Consistently use :encoding($encoding)