Skip to content

Crawlee—A web scraping and browser automation library for Node.js to build reliable crawlers. In JavaScript and TypeScript. Extract data for AI, LLMs, RAG, or GPTs. Download HTML, PDF, JPG, PNG, and other files from websites. Works with Puppeteer, Playwright, Cheerio, JSDOM, and raw HTTP. Both headful and headless mode. With proxy rotation.

Fixing typo

Marek Trunkat5d471d0a7f11
diff --git a/src/actor.js b/src/actor.js
index 23b9fefae..fa6a6708a 100644
--- a/src/actor.js
+++ b/src/actor.js
@@ -56,15 +56,15 @@ export const getValue = (key, callback = null) => {
});
})
.then((recordBody) => {
- if (!record) {
+ if (!recordBody) {
return null;
}
- if (!_.isString(recordBody) && !Buffer.isBuffer(record.body)) {
+ if (!_.isString(recordBody) && !Buffer.isBuffer(recordBody)) {
throw new Error('ApifyClient returned an unexpected value from keyValueStores.getRecord(): body must be String or Buffer.');
}
- return record.body;
+ return recordBody;
});
return nodeifyPromise(promise, callback);