Fix address of immonet (#47)

This commit is contained in:
Carl Ambroselli
2022-02-15 13:14:49 +01:00
committed by GitHub
parent 6e6144e02f
commit 5225098006
2 changed files with 2 additions and 2 deletions

View File

@@ -17,7 +17,7 @@ function normalize(o) {
return Object.assign(o, { id });
}
//apply blaclist if needed
//apply blacklist if needed
function applyBlacklist(o) {
const titleNotBlacklisted = !utils.isOneOf(o.title, appliedBlackList);
const descNotBlacklisted = !utils.isOneOf(o.description, appliedBlackList);

View File

@@ -6,7 +6,7 @@ function normalize(o) {
const id = parseInt(o.id.substring(o.id.indexOf('_') + 1, o.id.length));
const size = o.size != null ? o.size.replace('Wohnfläche ', '') : 'N/A m²';
const price = o.price.replace('Kaufpreis ', '');
const address = o.address.split(' • ')[1];
const address = o.address.split(' • ')[o.address.split(' • ').length - 1];
const title = o.title || 'No title available';
//normally we would just read the link from the source, but immonet decided to trick user by adding a click listener instead of
//a href to do some weird reporting. (Very user friendly for handicaped ppl... not)