diff --git a/README.md b/README.md index 1bb045e..f6ac8dd 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,11 @@


LinkedIn Jobs API

- - - - - - + + + + + +
## Features diff --git a/index.js b/index.js index 065a4b1..70eb7ee 100644 --- a/index.js +++ b/index.js @@ -13,8 +13,8 @@ function Query(queryObj) { this.host = queryObj.host || "www.linkedin.com"; //api handles strings with spaces by replacing the values with %20 - this.keyword = queryObj.keyword.replace(" ", "+") || ""; - this.location = queryObj.location.replace(" ", "+") || ""; + this.keyword = queryObj.keyword?.replace(" ", "+") || ""; + this.location = queryObj.location?.replace(" ", "+") || ""; this.dateSincePosted = queryObj.dateSincePosted || ""; this.jobType = queryObj.jobType || ""; this.remoteFilter = queryObj.remoteFilter || "";