I think you might be able to rebuild MM…
cd MagicMirror
npm rebuild
it takes a few minutes, but that is one thing that has helped me in the past fix several different errors.
Also, you can re-install the MM and your modules, especially the last one you added prior to getting this error…
Start with the last module… cd modules/[last-module-name] >>> npm install
Then run the npm install with MM. Or, the npm rebuild
then restart MM
Also, try rebooting the Pi by shutting it off, then turn it back on.
(works better to help fix errors than using restart)