summaryrefslogtreecommitdiff
path: root/gitlab/exceptions.py
diff options
context:
space:
mode:
authorGauvain Pocentek <gauvain@pocentek.net>2017-08-11 08:19:37 +0200
committerGauvain Pocentek <gauvain@pocentek.net>2017-08-11 08:19:37 +0200
commit4ed22b1594fd16d93fcdcaab7db8c467afd41fea (patch)
tree7e81569820a252ad40cabf883bcca0ed06e331d8 /gitlab/exceptions.py
parentd1e7cc797a379be3f434d0e275d14486f858f80e (diff)
downloadgitlab-4ed22b1594fd16d93fcdcaab7db8c467afd41fea.tar.gz
on_http_error: properly wrap the function
This fixes the API docs.
Diffstat (limited to 'gitlab/exceptions.py')
-rw-r--r--gitlab/exceptions.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/gitlab/exceptions.py b/gitlab/exceptions.py
index 6c00129..fc2c162 100644
--- a/gitlab/exceptions.py
+++ b/gitlab/exceptions.py
@@ -15,6 +15,8 @@
# You should have received a copy of the GNU Lesser General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+import functools
+
class GitlabError(Exception):
def __init__(self, error_message="", response_code=None,
@@ -223,6 +225,7 @@ def on_http_error(error):
GitlabError
"""
def wrap(f):
+ @functools.wraps(f)
def wrapped_f(*args, **kwargs):
try:
return f(*args, **kwargs)