kopia lustrzana https://github.com/badgen/badgen.net
fix(pub): correct scraping regex (#469)
rodzic
aa5c80702e
commit
ec492dd0f4
|
@ -50,7 +50,7 @@ async function webHandler({ topic, pkg }: PathArgs) {
|
|||
|
||||
switch (topic) {
|
||||
case 'likes': {
|
||||
const likes = html.match(/id="likes-count">([^<]+)</i)?.[1].trim() ?? ''
|
||||
const likes = html.match(/id="likes-count">([^<]+)<\//i)?.[1].trim() ?? ''
|
||||
return {
|
||||
subject: 'likes',
|
||||
status: likes,
|
||||
|
|
Ładowanie…
Reference in New Issue