From a26e58585b3d82cf1a3e60a3b7b3bfd7f51d77e5 Mon Sep 17 00:00:00 2001 From: Nejc Habjan Date: Sat, 28 Mar 2020 18:52:29 +0100 Subject: fix(types): do not split single value string in ListAttribute --- gitlab/types.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gitlab/types.py b/gitlab/types.py index 525dc30..e07d078 100644 --- a/gitlab/types.py +++ b/gitlab/types.py @@ -38,6 +38,10 @@ class ListAttribute(GitlabAttribute): self._value = [item.strip() for item in cli_value.split(",")] def get_for_api(self): + # Do not comma-split single value passed as string + if isinstance(self._value, str): + return self._value + return ",".join(self._value) -- cgit v1.2.1