Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

trollbox

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

trollbox - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

2

package.json
{
"name": "trollbox",
"version": "0.0.4",
"version": "0.0.5",
"description": "",

@@ -5,0 +5,0 @@ "main": "trollbox.js",

@@ -9,2 +9,4 @@ (function (root) {

var config = null
function Trollbox (config) {

@@ -33,4 +35,13 @@ const scriptId = 'FirebaseScript'

function onLoad (config) {
const user = config.user || 'anon'
function onLoad (_config) {
_config.user = _config.user || 'anon'
if (config) {
config.channel = _config.channel
config.user = _config.user
return false
} else {
config = _config
}
const ref = initFirebase(config)

@@ -41,3 +52,3 @@ renderBox(config.container)

ref.push().set({
user: user,
user: config.user,
message: message,

@@ -66,17 +77,6 @@ date: (Date.now() / 1e3) | 0

var ref = null
var app = window.firebase.initializeApp(config.firebase)
var db = app.database()
var ref = db.ref(`trollbox/${channel}`)
if (window.firebaseApp) {
ref = window.firebaseApp.ref
} else {
var app = window.firebase.initializeApp(config.firebase)
var db = app.database()
ref = db.ref(`trollbox/${channel}`)
window.firebaseCache = {
db: db,
ref: ref
}
}
return ref

@@ -83,0 +83,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc