Remove unnecessary realpath calls