Update Equella Module to not show errors in 2.6

I received a lot of errors regarding get_context_instance being deprecated, so I have updated them now to be context_xxx::instance(). That created another error about $course->category being 0 in common/lib.php (equella_getssotoken()).
I have also updated some of the coding style to be the Moodle style as well as removing all tabs to be replaced with 4 spaces.