Refactor confusing case statement in the resourceFactory action method.

Request Type: refactor

How to reproduce: not a bug, just confusing code

Component(s): ngResource

Impact: small

Complexity: small

This issue is related to: performance regression

**Detailed Description:**

A coworker ran across the case statement at the beginning of the resourceFactory action method definition. I refactored it so it's clearer what's going on. As a result, the jshint exception is no longer needed. Tests pass, but we have not tried it in a production app yet.

**Other Comments:**