Skip to content

Commit

Permalink
fix(crawler/ks): adapt regex
Browse files Browse the repository at this point in the history
  • Loading branch information
kkkrist committed Mar 1, 2021
1 parent f6d9936 commit 42385ff
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/crawler/lib/ks.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ module.exports = () =>
dom => {
const dateMatch = [...dom.window.document.querySelectorAll('h3')]
.find(el => /^Stand/.test(el.textContent))
.textContent.match(/Stand: \w+, ([0-9]+). (\w+) ([0-9]+)/)
.textContent.match(/Stand:\s\w+,\s(\d*)\.\s([\wä]+)\s(\d{4})/)

if (!dateMatch) {
throw new Error("Couldn't parse date")
Expand Down

0 comments on commit 42385ff

Please sign in to comment.