New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

solr-search

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

solr-search - npm Package Compare versions

Comparing version 0.1.1 to 0.1.3

lib/Select.js

38

index.js
'use strict';
module.exports = require('./lib/solr');
/*
var request = require('./lib/request'),
colog = require('colog');
var simpleSelect = 'http://localhost:8983/solr/dariuszp/select?&q=*:*&wt=json&indent=true';
var update = 'http://localhost:8983/solr/update?commit=true&wt=json';
request.post(update, '<add><doc><field name="id">1</field><field name="title">Hello</field></doc><doc><field name="id">2</field><field name="title">world</field></doc></add>', function (data) {
colog.dump(data, ['green', 'bold']);
});
request.get(simpleSelect, function (data) {
colog.dump(JSON.parse(data), ['red', 'bgWhite', 'bold']);
});*/
//var solr = require('./lib/solr'),
// colog = require('colog');
//
//solr.addClient('dariuszp');
//
//var dc = solr.getClient('dariuszp');
//
//dc.getCollection('dariuszp', function (collection) {
// collection.select().query('*:*', {
// fq: 'title:Hello',
// fl: ['title'],
// sort: { 'id': 'ASC' },
// 'success': function (se) {
// console.log(se.docs());
// },
// 'error': function (err) {
// console.log(err.toString());
// }
// });
//});
module.exports = require('./lib/solr');

@@ -8,3 +8,4 @@ 'use strict';

events = require('events'),
Select = require('./select');
Select = require('./Select'),
SolrDocument = require('./SolrDocument');

@@ -176,4 +177,9 @@ function convertType(val) {

if ((document instanceof Object) === false) {
throw new Error('Document must be a JSON object');
throw new Error('Document must be a JSON object or SolrDocument type');
}
if (document instanceof SolrDocument) {
document = document.getRawData();
}
for (field in document) {

@@ -180,0 +186,0 @@ if (document.hasOwnProperty(field)) {

{
"name": "solr-search",
"version": "0.1.1",
"version": "0.1.3",
"author": "Półtorak Dariusz <poltorak.dariusz@gmail.com>",

@@ -14,3 +14,2 @@ "description": "Small solr client",

"main": "index.js",
"bin": "bin/solr.js",
"keywords": [

@@ -17,0 +16,0 @@ "solr",

@@ -1,2 +0,2 @@

solr-search v0.1.0
solr-search v0.1.3
====

@@ -3,0 +3,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