Remove the bind variable declaration

@inner
@param {Object} t the babel type definition
@param {Object} bindVar the bind variable path information
@param {Object} removeOpts the remove options
function removeVariableDeclaration(t, bindVar, removeOpts) {
    let refPaths = bindVar.referencePaths || [];
    let removed;

    // try to remove the bind variable in multiple variable declarations
    refPaths.forEach(item => {
        let parentPath = item.getStatementParent();
        if (t.isVariableDeclaration(parentPath) && t.isIdentifier(item)) {
            removeNode(t, item.parentPath, removeOpts);
            removeComments(t, parentPath, 'leadingComments');
            removed = true;
        }
    });

    // if not multiple variable declarations,
    // remove the single variable declaration statement
    if (!removed) {
        removeNode(t, bindVar.path.getStatementParent(), removeOpts);
    }
}