Skip to content

Commit 11fc8db

Browse files
crzypatchworkcrzypatchwork
authored andcommitted
latest
1 parent 1016470 commit 11fc8db

File tree

3 files changed

+22
-15
lines changed

3 files changed

+22
-15
lines changed

.env

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
REACT_APP_IPFS_KEY='eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJkaWQ6ZXRocjoweEY1NDdDNUIyMjMzMTc3MDZkZDdkODNEMjA4ODRkRDgxOTIxNTBiNEUiLCJpc3MiOiJuZnQtc3RvcmFnZSIsImlhdCI6MTYzMTA1NTgyNTAxMCwibmFtZSI6ImRldiJ9.Uw_dgYXOAA1znTrdXlOlXFYWh9U_pjg4QOl7nrt16SA'
22

3-
REACT_APP_BLOCKLIST_OBJKT='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc/main/filters/o.json'
4-
REACT_APP_BLOCKLIST_WALLET='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc/main/filters/w.json'
5-
REACT_APP_BLOCKLIST_BAN='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc/main/filters/b.json'
3+
REACT_APP_BLOCKLIST_OBJKT='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc-reports/main/filters/o.json'
4+
REACT_APP_BLOCKLIST_WALLET='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc-reports/main/filters/w.json'
5+
REACT_APP_BLOCKLIST_BAN='https://raw.githubusercontent.com/hicetnunc2000/hicetnunc-reports/main/filters/b.json'
66

7-
REACT_APP_GRAPHQL_API='https://hdapi.teztools.io/v1/graphql'
7+
REACT_APP_GRAPHQL_API='https://hdapi.teztools.io/v1/graphql'

src/components/media-types/image/index.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ export const ImageComponent = ({
1111
displayView
1212
}) => {
1313
let src = onDetailView ? artifactUri : displayUri || artifactUri
14-
console.log('src', src)
15-
console.log('artifact', artifactUri, 'display', displayUri)
14+
1615
if (preview) {
1716
src = previewUri
1817
}

src/pages/feeds/feeds.js

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,19 @@ const customFloor = function (value, roundTo) {
2020
return Math.floor(value / roundTo) * roundTo
2121
}
2222

23-
const tz_profiles = `
24-
query profiles {
25-
tzprofiles(where: {account: {_in: $arr }}) {
26-
account
27-
contract
28-
}
23+
const GetUserClaims = async (arr) => {
24+
console.log(JSON.stringify(arr))
25+
return await axios.post('https://indexer.tzprofiles.com/v1/graphql', {
26+
query: `query MyQuery {
27+
tzprofiles(where: {account: {_in: ${JSON.stringify(arr)}}}) {
28+
account
29+
valid_claims
30+
}
31+
}`,
32+
variables: undefined,
33+
operationName: 'MyQuery',
34+
})
2935
}
30-
`
3136

3237
const latest_feed = `
3338
query LatestFeed($lastId: bigint = 99999999) {
@@ -66,7 +71,9 @@ const query_hdao = `query hDAOFeed($offset: Int = 0) {
6671
}`
6772

6873
async function fetchProfiles(arr) {
69-
const { errors, data } = await fetchGraphQLProfiles(tz_profiles, "profiles", { "arr": arr })
74+
const { errors, data } = await fetchGraphQLProfiles(
75+
tzprofiles, "MyQuery", {})
76+
console.log(data)
7077
return data.tzprofiles
7178
}
7279

@@ -254,7 +261,8 @@ export const Feeds = ({ type }) => {
254261
result = _.uniqBy(result, 'creator_id')
255262
setCreators(creators.concat(result.map(e => e.creator_id)))
256263
result = result.filter(e => !creators.includes(e.creator_id))
257-
264+
let arr = result.map(e => e.creator_id)
265+
console.log(await GetUserClaims(arr))
258266
let restricted = await getRestrictedAddresses()
259267
result = result.filter(e => !restricted.includes(e.creator_id))
260268
const next = items.concat(result)

0 commit comments

Comments
 (0)