Using options instead of config dependency for common location resolver.
This commit is contained in:
parent
eb519ef474
commit
928650b602
2
common
2
common
|
@ -1 +1 @@
|
|||
Subproject commit 4316b69a43daeaa7ddadb428ccc6cb3eb10f555e
|
||||
Subproject commit 7a39529e2c20faa7153b8ffe932842e30b46aeb4
|
|
@ -39,7 +39,6 @@ const { resolveLayoutScraper } = require('./scrapers/resolve');
|
|||
const getRecursiveParameters = require('./utils/get-recursive-parameters');
|
||||
|
||||
const commonContext = {
|
||||
argv,
|
||||
knex,
|
||||
redis,
|
||||
logger,
|
||||
|
@ -474,8 +473,8 @@ async function curateProfile(profile, actor) {
|
|||
|
||||
if (argv.resolvePlace) {
|
||||
const [placeOfBirth, placeOfResidence] = await Promise.all([
|
||||
resolvePlace(profile.birthPlace, commonContext),
|
||||
resolvePlace(profile.residencePlace, commonContext),
|
||||
resolvePlace(profile.birthPlace, commonContext, { useCache: argv.placeCache, userAgent: config.location.userAgent }),
|
||||
resolvePlace(profile.residencePlace, commonContext, { useCache: argv.placeCache, userAgent: config.location.userAgent }),
|
||||
]);
|
||||
|
||||
curatedProfile.placeOfBirth = placeOfBirth;
|
||||
|
|
Loading…
Reference in New Issue