fixed issue with trying to write to root