The going-and-coming rule says that commute to and from work is outside the scope of one's employment.
The going-and-coming rule does not apply when an employee endangers others with a risk arising from or related to work. This is determined by if it "was a generally foreseeable consequence of the activity." The conduct is foreseeable if it is not so startling or unusual that it would seem unfair to include the loss as part of the employer's cost of doing business.
A slight deviation for the comfort, convenience, health, and welfare of the employee while at work is not outside the scope of employment if the conduct is not a substantial deviation from the duties of employment.