prof18/RSS-Parser

Selects video instead of images

Closed this issue · 0 comments

I tried to parse Rss feed autonews and noticed 1 unpleasant moment if the feed has many url ,so if the last url has type "video/mp4" the parser still tries to use it as a picture and uses in currentArcticle.image
Снимок экрана от 2020-04-05 19 00 07
Well,i guess it happens because of in "else" part,parser doesnt check "image" tegs and if url is not null,get it in currentArticle and cant load as image
vv

Also,if the feed has a lot of url just images,it will use just a last image ,but may be the best choice to use the first photo,well it's the preview image usually

the link of Rss feed : https://motor.ru/exports/rss.xml