mirror of
https://github.com/logos-storage/ethcc-demo.git
synced 2026-01-06 23:23:09 +00:00
codex plugin cleanup
This commit is contained in:
parent
342eba171c
commit
3fb5a59069
@ -1,19 +1,9 @@
|
||||
export default {
|
||||
install: (app, { codexRestUrl, myAddress }) => {
|
||||
// const baseUrl = new URL(codexRestUrl)
|
||||
const options = {
|
||||
mode: 'cors'
|
||||
}
|
||||
const codexApi = {
|
||||
info: () => {
|
||||
return fetch(`${codexRestUrl}/debug/info`, options)
|
||||
},
|
||||
download: (cid) => {
|
||||
return fetch(`${codexRestUrl}/data/${cid}/network`, options)
|
||||
},
|
||||
downloadLocal: (cid) => {
|
||||
return fetch(`${codexRestUrl}/data/${cid}`, options)
|
||||
}
|
||||
info: () => fetch(`${codexRestUrl}/debug/info`),
|
||||
download: (cid) => fetch(`${codexRestUrl}/data/${cid}/network`),
|
||||
downloadLocal: (cid) => fetch(`${codexRestUrl}/data/${cid}`)
|
||||
}
|
||||
|
||||
app.provide('myAddress', myAddress)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user