~doanac/+junk/lander-progress-trigger

« back to all changes in this revision

Viewing changes to ci-utils/ci_utils/tastypie/resource.py

  • Committer: Tarmac
  • Author(s): Andy Doan
  • Date: 2014-01-02 14:45:35 UTC
  • mfrom: (65.1.1 bug1263192)
  • Revision ID: tarmac-20140102144535-l8y4bds7rn6jgmxd
[r=Evan Dandrea, Parameswaran Sivatharman] disable authorizization in tastypie util
  
don't know how unit-testing missed this while disabling authentication.
there was even a broken test this fixes.
 1263192 from Andy Doan

Show diffs side-by-side

added added

removed removed

Lines of Context:
14
14
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
15
15
 
16
16
from tastypie.authentication import Authentication
17
 
from tastypie.authorization import DjangoAuthorization
 
17
from tastypie.authorization import Authorization
18
18
from tastypie.resources import ModelResource
19
19
 
20
20
# don't allow deletion of objects with this API
29
29
        return super(WriteAuthentication, self).is_authenticated(req, **kwargs)
30
30
 
31
31
 
32
 
class WriteAuthorization(DjangoAuthorization):
 
32
class WriteAuthorization(Authorization):
33
33
    '''only require authorization for non-GET operations.'''
34
34
 
35
35
    def is_authorized(self, req, object=None):