For some reason, many of the applications' icons in the Dock's Applications folder were replaced by the default application icon. I've tried to clear the icon cache, but that didn't work. Below is a screenshot of the problem.
How do I restore those icons? And for that matter, why did this happen in the first place?
I'm running MacOS Sierra on a MacBook Pro Mid 2014.