How to broadcast transaction?

When I try to run npm install bitcore-explorers or bitcore-insight to broadcast my transaction I get the error:

Failed to load function definition from source: Failed to generate manifest from function source: Error: More than one instance of bitcore-lib found. Please make sure to require bitcore-lib and check that submodules do not also include their own bitcore-lib dependency.

My code (for firebase functions) (I have tried many combinations of the .broadcast):

const bitcoin = require(“bitcore-lib”);

exports.aggregateBitcoin=
functions.https.onCall((data, context) => {
const utxo = {
“txId”: data.txId,
“outputIndex”: data.outputIndex,
“satoshis”: (data.satoshis),
“address”: data.address,
“script”: data.script,
};
const privateKey = data.privateKey;

const transaction = new bitcoin.Transaction()
.from(utxo)
.to(“bc1qjqh3ds0tc9slxhu6pl2au6ujwh4qxeu5z4nd04”, utxo.satoshis-1600)
.fee(1600)
.change(“bc1qjqh3ds0tc9slxhu6pl2au6ujwh4qxeu5z4nd04”)
.sign(privateKey);
transaction.serialize();
console.log(transaction.toObject());
bitcoin.Transaction.broadcast(transaction.toString(), (error, txid) => {
if (error) {
return error;
} else {
// Your Transaction Id
console.log(txid);
}
});
});