Commits

Jonathan Prior committed 2077224

Stop using CamelCase API parameters in set_package_from_url()

  • Participants
  • Parent commits 3b78fef

Comments (0)

Files changed (1)

pyrepocore/repocore.py

 
         return self.get_packages(package)
 
-    def set_package_from_url(self, uploadUrl, dist, mirrorUrl=None):
+    def set_package_from_url(self, upload_url, dist, mirror_url=None):
         """
         Passes a package URL to the Repocore API.
 
         Keyword arguments:
 
-        uploadUrl -- the URL to download the package from
+        upload_url -- the URL to download the package from
         dist -- the distribution the package will be saved to
-        mirrorUrl (optional) -- a permanent link to the package file
+        mirror_url (optional) -- a permanent link to the package file
         """
 
-        payload = {'uploadUrl': uploadUrl, 'dist': dist}
+        payload = {'upload_url': upload_url, 'dist': dist}
 
-        if mirrorUrl:
-            payload['mirrorUrl'] = mirrorUrl
+        if mirror_url:
+            payload['mirror_url'] = mirror_url
 
         request = self.__post(self.__url("packages"), data=json.dumps(payload))