def METHOD_NAME(node, tx):
    """Check that all inputs are of the same OutputType"""
    vins = node.getrawtransaction(tx, True)['vin']
    inputs = []
    for vin in vins:
        prev_tx, n = vin['txid'], vin['vout']
        inputs.append(
            node.getrawtransaction(
                prev_tx,
                True,
            )['vout'][n]['scriptPubKey']['address']
        )
    has_legacy = False
    has_p2sh = False
    has_bech32 = False
    has_bech32m = False
    for addr in inputs:
        if is_legacy_address(node, addr):
            has_legacy = True
        if is_p2sh_segwit_address(node, addr):
            has_p2sh = True
        if is_bech32_address(node, addr):
            has_bech32 = True
        if is_bech32m_address(node, addr):
            has_bech32m = True
    return (sum([has_legacy, has_p2sh, has_bech32, has_bech32m]) == 1)