Skip to content

Commit

Permalink
code refactored
Browse files Browse the repository at this point in the history
  • Loading branch information
freelancing-solutions committed Jan 8, 2022
1 parent 77bdbaf commit 85944b9
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 13 deletions.
2 changes: 1 addition & 1 deletion _ipn/micro_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
@microservices_ipn_bp.route('/_ipn/micro-services/auth', methods=["POST"])
def micro_services_auth() -> tuple:
"""
will authenticate a web application to this API
:return:
"""
json_data: dict = request.get_json()
Expand Down
12 changes: 5 additions & 7 deletions _ipn/paypal.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,14 @@
__github_profile__ = "https://github.com/freelancing-solutions/"

from flask import Blueprint


paypal_ipn_bp = Blueprint("paypal_ipn", __name__)


@paypal_ipn_bp.route('/_ipn/paypal/deposit/success/<path:path>', methods=["GET", "POST"])
def deposit_successfull_ipn(path: str) -> tuple:
def deposit_successful_ipn(path: str) -> tuple:
"""
**deposit_successfull_ipn**
deposit is successfull capture the approve url and redirect the user there after saving the deposit
**deposit_successful_ipn**
deposit is successful capture the approve url and redirect the user there after saving the deposit
details to the store
:param path: organization_id
Expand Down Expand Up @@ -69,9 +67,9 @@ def withdrawal_failed_ipn(path: str) -> tuple:


@paypal_ipn_bp.route('/_ipn/paypal/withdrawal/success/<path:path>', methods=["GET", "POST"])
def withdrawal_successfull_ipn(path: str) -> tuple:
def withdrawal_successful_ipn(path: str) -> tuple:
"""
**withdrawal_successfull_ipn**
**withdrawal_successful_ipn**
:param path: organization_id
:return: "OK", 200
Expand Down
1 change: 0 additions & 1 deletion _swagger_api/schemas/users.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
from datetime import datetime, date
from _swagger_api.schemas.address import AddressSchema
from _swagger_api.schemas.response import ResponseSchema
from utils import create_id


class UserPayloadSchema(Schema):
Expand Down
4 changes: 0 additions & 4 deletions _swagger_api/wallet/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
Swagger Compatible API for wallet
"""
from __future__ import annotations

from typing import List, Callable

from flask_apispec import doc, marshal_with, use_kwargs
from _swagger_api import ViewModel
from _swagger_api.schemas.wallet import WalletResponseSchema, WalletListResponseSchema, WalletRequestSchema
Expand Down Expand Up @@ -86,8 +84,6 @@ class WalletListView(ViewModel):
**WalletListView**
returns a list of all wallets for a specific organization
"""
methods = ["GET"]
method_decorators = [handle_api_auth]

def __new__(cls, *args, **kwargs) -> WalletListView:
"""
Expand Down

0 comments on commit 85944b9

Please sign in to comment.