"You saved me tons of work"
— Tanner Moushey What They Say

Why do I see “syntax error, unexpected end”?

If you moved / migrated your website or uploaded a theme or plugin using FTP, you may see an “unexpected end” syntax error. This is likely because one or more theme or plugin files were corrupted during the transfer.

Examine the error to determine which theme or plugin is affected.

If using FTP, re-upload the theme or plugin using BINARY or AUTO mode instead of ASCII.

You can also re-install the theme and any plugin mentioned in the error using your WordPress admin area. If you need to delete the theme manually because you cannot access the admin area, use FTP to delete or rename wp-content/themes/yourtheme, then you can reinstall it.

Make sure you use the latest version of a theme or plugin when reinstalling it.