Merge branch 'master' into api_versioning
Conflicts: tests/test_tags.py
This commit is contained in:
commit
1b2f0cd869
8 changed files with 76 additions and 62 deletions
|
@ -1,3 +1,4 @@
|
|||
import urllib
|
||||
from errors import *
|
||||
|
||||
class OpenPhotoObject:
|
||||
|
@ -122,13 +123,13 @@ class Tag(OpenPhotoObject):
|
|||
Returns True if successful.
|
||||
Raises an OpenPhotoError if not.
|
||||
"""
|
||||
result = self._openphoto.post("/tag/%s/delete.json" % self.id, **kwds)["result"]
|
||||
result = self._openphoto.post("/tag/%s/delete.json" % urllib.quote(self.id), **kwds)["result"]
|
||||
self._replace_fields({})
|
||||
return result
|
||||
|
||||
def update(self, **kwds):
|
||||
""" Update this tag with the specified parameters """
|
||||
new_dict = self._openphoto.post("/tag/%s/update.json" % self.id,
|
||||
new_dict = self._openphoto.post("/tag/%s/update.json" % urllib.quote(self.id),
|
||||
**kwds)["result"]
|
||||
self._replace_fields(new_dict)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue