Fix ReferenceError: fs is not defined