# All files / src/api/methods getColors.js

100% Statements 7/7
100% Branches 4/4
100% Functions 1/1
100% Lines 7/7

Press n or j to go to the next uncovered block, b, p or k for the previous block.

    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20

    9x
    128x
    39x

    89x
    41x

    48x

    9x
     /**
     * Copyright (c) 2018-present, Leap DAO (leapdao.org)
     *
     * This source code is licensed under the Mozilla Public License Version 2.0
     * found in the LICENSE file in the root directory of this source tree.
     */

    const getColors = async (bridgeState, nft, nst) => {
      if (nft) {
        return bridgeState.tokens.erc721;
      }
      if (nst) {
        return bridgeState.tokens.erc1948;
      }

      return bridgeState.tokens.erc20;
    };

    module.exports = getColors;