Skip to content

Commit

Permalink
Merge 3137618 into 1b6f4b5
Browse files Browse the repository at this point in the history
  • Loading branch information
okraskaj committed Dec 3, 2018
2 parents 1b6f4b5 + 3137618 commit c8f26fc
Showing 1 changed file with 9 additions and 16 deletions.
25 changes: 9 additions & 16 deletions reana_commons/api_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,8 @@
# This file is part of REANA.
# Copyright (C) 2018 CERN.
#
# REANA is free software; you can redistribute it and/or modify it under the
# terms of the GNU General Public License as published by the Free Software
# Foundation; either version 2 of the License, or (at your option) any later
# version.
#
# REANA is distributed in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
# A PARTICULAR PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with
# REANA; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
# Suite 330, Boston, MA 02111-1307, USA.
#
# In applying this license, CERN does not waive the privileges and immunities
# granted to it by virtue of its status as an Intergovernmental Organization or
# submit itself to any jurisdiction.
# REANA is free software; you can redistribute it and/or modify it
# under the terms of the MIT License; see LICENSE file for more details.
"""REANA REST API base client."""

import json
Expand Down Expand Up @@ -132,3 +118,10 @@ def check_if_cached(self, job_spec, step, workflow_workspace):
raise HTTPInternalServerError('Internal Server Error. Error: {}'.
format(http_response.data))
return http_response


def get_current_api_client(component):
"""Return current state of the search extension."""
rwc_api_client = BaseAPIClient(component)

return rwc_api_client._client

0 comments on commit c8f26fc

Please sign in to comment.