The java on your mac can easily become outdated. Apple doesn't love java, so the auto tools to "update" it often don't work. Here's how you can check which version you're currently on, and how to remove it.
Note: the current version of Java JDK is V10. (8/23/18) found here.
Check the current version:
I like the stable Java Version 8. Found here.
We're some guys and gals in San Francisco who fix macs. We can remote in and help you with stuff. It's like our job or whatever.
(five one zero) 761-6559
**We charge $1.28/minute for quick fixes.