Skip to content

Commit

Permalink
πŸ”€ Merge #486 updates to deploy/rinkeby
Browse files Browse the repository at this point in the history
  • Loading branch information
AuroraHuang22 committed Sep 27, 2024
2 parents 29c61fa + d89d3f2 commit b537781
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pages/nft/url/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -643,10 +643,15 @@ export default class FetchIndex extends Vue {
}
async crawlUrlData() {
const isNewsPress = !!this.$route.query.news_press && this.$route.query.news_press !== '0'
try {
logTrackerEvent(this, 'NFTUrlMint', 'CrawlUrlData', this.url, 1);
const { data } = await this.$axios.get(`/crawler/?url=${encodeURIComponent(this.encodedURL)}&wallet=${this.address}`)
const { title, description, keywords, author, body, images = [] } = data
const { title, description, author, body, images = [] } = data;
let {keywords} = data;
if(isNewsPress) {
keywords = keywords ? `${keywords},NewsPress` : 'NewsPress';
}
if (!body) { throw new Error('CANNOT_CRAWL_THIS_URL') }
if (title === 'patreon.com' && description === '') { throw new Error('SITE_NOT_CRAWLABLE: pateron') }
this.iscnData = { title, description, keywords, author }
Expand Down

0 comments on commit b537781

Please sign in to comment.