Fix encode path