Comments (1)
Found the problem, this is a server-side problem, where the the string will be split into many substrings at any comma.
Line 50 in 241f981
@vasanthv
By adding this reduce
function between the split
and the forEach
will solve the problem
req_q
.split(',')
.reduce((v, x) => {
x.includes(':') ? v.push(x) : v[v.length-1] += (',' + x)
return v
}, [])
.forEach(i => (q[i.split(':')[0]] = i.split(':')[1]));
Or changing the code a little bit with regex
(I don't know much about regex, so this may contains bugs, idk)
req_q
.split(/,?(\w+):/)
.slice(1)
.reduce((v, x, i) => {
i % 2 == 0 ? v.push([x]) : v[v.length-1].push(x)
return v
}, [])
.forEach(([key, value]) => { ... })
from jsonbox.
Related Issues (20)
- Rename "private boxes" to "protected boxes" HOT 3
- Standardize and document response schema HOT 4
- Support additional string/primitive query values HOT 1
- [feature request] create capped box (collection) HOT 1
- [discussion] Remove the old unused data. HOT 5
- Is it possible to filter by _createdOn? HOT 1
- suggestion: Make README into Github Pages? HOT 1
- Suggestion: add rate limit to config.js?
- where I can edit the limit of 5000 records in this src HOT 2
- [feature request] allow IP whitelisting to access self hosted jsonbox HOT 2
- Is it possible not to use Cloudflare? HOT 1
- How to get API_ KEY HOT 4
- 50kb limit is actually 35kb? HOT 1
- Max Records in box 20 HOT 1
- jsonbox returning 'application error'
- Delete operation non existing id need not throw error
- Request handling slow HOT 1
- Any alternative after the termination of service jsonbox.io ? HOT 8
- Is there any kind of dashboard.
- Question about limitations
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jsonbox.