Revert "fix prefernece convertion from string"

This reverts commit e3e81833136c8e9ff4d5110d59b090cb557c0932.