Skip to content

Commit

Permalink
v. 0.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
Maqentaer committed Feb 17, 2014
1 parent 7c0993b commit 97181f5
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var jsonMl = html2jsonml( <string> html [, <object> options ] [, <func> callback
```

##Options
for supporting not JSONML standards and others:
for supporting not JSONML standards and others parser options:
```javascript
var options = {
// Add attributes object in any case (false by default):
Expand Down
3 changes: 2 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,11 @@ var htmlparser2 = require('htmlparser2');
*/
module.exports = function(html, options, callback)
{
if(typeof options === 'function' || typeof options === 'undefined'){
if(typeof options === 'function'){
callback = options;
options = {};
}
options = options || {};
var errors = null;
var jsonMl = null;
if(typeof html === 'string'){
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "html2jsonml",
"version": "0.0.3",
"version": "0.0.4",
"description": "Convert HTML to JSONML",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit 97181f5

Please sign in to comment.