| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -420,7 +420,7 @@ def update(self, obj, **kwargs): | |||
| 420 | 420 | headers = self._createHeaders(content_type="application/json") | |
| 421 | 421 | ||
| 422 | 422 | # build data that can really be sent to server | |
| 423 | - data = obj._dataForGitlab() | ||
| 423 | + data = obj._dataForGitlab(extra_parameters=kwargs) | ||
| 424 | 424 | ||
| 425 | 425 | try: | |
| 426 | 426 | r = requests.put(url, data=data, | |
@@ -942,9 +942,10 @@ class ProjectIssue(GitlabObject): | |||
| 942 | 942 | def _dataForGitlab(self, extra_parameters={}): | |
| 943 | 943 | # Gitlab-api returns labels in a json list and takes them in a | |
| 944 | 944 | # comma separated list. | |
| 945 | - if hasattr(self, "labels") and self.labels is not None: | ||
| 946 | - labels = ", ".join(self.labels) | ||
| 947 | - extra_parameters.update(labels) | ||
| 945 | + if hasattr(self, "labels"): | ||
| 946 | + if self.labels is not None and not isinstance(self.labels, six.string_types): | ||
| 947 | + labels = ", ".join(self.labels) | ||
| 948 | + extra_parameters['labels'] = labels | ||
| 948 | 949 | ||
| 949 | 950 | return super(ProjectIssue, self)._dataForGitlab(extra_parameters) | |
| 950 | 951 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments