Skip to content

Commit d3b800f

Browse files
fix: remove orbis config
1 parent bafa3a0 commit d3b800f

File tree

4 files changed

+43
-64
lines changed

4 files changed

+43
-64
lines changed

.env

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,2 @@
11
PORT=4000
22
NEXT_PUBLIC_DASHBOARD_API=https://app.plurality.local
3-
4-
# Orbis
5-
NEXT_PUBLIC_CERAMIC_URL=https://ceramic-orbisdb-mainnet-direct.hirenodes.io/
6-
NEXT_PUBLIC_ORBIS_NODE_URL=https://studio.useorbis.com
7-
NEXT_PUBLIC_ORBIS_ENV=did:pkh:eip155:1:0x49b330af2e9b16189a55d45bcf808d2d92bce1f6
8-
NEXT_PUBLIC_PLURALITY_CONTEXT=kjzl6kcym7w8y5af2n9u66uif7kb9xqxstaybypzg3hewlm7y1cg2746mo6dbkj
9-
NEXT_PUBLIC_PROFILE_TYPE_MODEL=kjzl6hvfrbw6c604bf1hd7tfooalbcgzwvu3aprhghe7t6k96tb5iowkjo7f1ps

.env.production.example

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1 @@
11
NEXT_PUBLIC_DASHBOARD_API=https://app.plurality.network/api
2-
3-
# Orbis
4-
NEXT_PUBLIC_CERAMIC_URL=https://ceramic-orbisdb-mainnet-direct.hirenodes.io/
5-
NEXT_PUBLIC_ORBIS_NODE_URL=https://studio.useorbis.com
6-
NEXT_PUBLIC_ORBIS_ENV=did:pkh:eip155:1:0x75ae41fd57f7f0ffdfdab923cae384944764e743
7-
NEXT_PUBLIC_PLURALITY_CONTEXT=kjzl6kcym7w8yb7hqhsjcbdikv8valtk5quvnbt1xbkzdlf8snqi9flidx6t35y
8-
NEXT_PUBLIC_PROFILE_TYPE_MODEL=kjzl6hvfrbw6cavbybdjvudbpn7in15h7zdlk6dg5h31o9s6qsfew32ky0qty19

.env.staging.example

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1 @@
11
NEXT_PUBLIC_DASHBOARD_API=https://app.plurality.local
2-
3-
# Orbis
4-
NEXT_PUBLIC_CERAMIC_URL=https://ceramic-orbisdb-mainnet-direct.hirenodes.io/
5-
NEXT_PUBLIC_ORBIS_NODE_URL=https://studio.useorbis.com
6-
NEXT_PUBLIC_ORBIS_ENV=did:pkh:eip155:1:0x49b330af2e9b16189a55d45bcf808d2d92bce1f6
7-
NEXT_PUBLIC_PLURALITY_CONTEXT=kjzl6kcym7w8y5af2n9u66uif7kb9xqxstaybypzg3hewlm7y1cg2746mo6dbkj
8-
NEXT_PUBLIC_PROFILE_TYPE_MODEL=kjzl6hvfrbw6c604bf1hd7tfooalbcgzwvu3aprhghe7t6k96tb5iowkjo7f1ps

lib/orbis-utils.ts

Lines changed: 43 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,50 +1,50 @@
1-
import { OrbisDB } from "@useorbis/db-sdk";
1+
//import { OrbisDB } from "@useorbis/db-sdk";
22
import axios from "axios";
33

4-
const orbisdb = new OrbisDB({
5-
ceramic: {
6-
gateway: process.env.NEXT_PUBLIC_CERAMIC_URL || ''
7-
},
8-
nodes: [
9-
{
10-
gateway: process.env.NEXT_PUBLIC_ORBIS_NODE_URL || '',
11-
env: process.env.NEXT_PUBLIC_ORBIS_ENV || ''
12-
}
13-
]
14-
})
4+
// const orbisdb = new OrbisDB({
5+
// ceramic: {
6+
// gateway: process.env.NEXT_PUBLIC_CERAMIC_URL || ''
7+
// },
8+
// nodes: [
9+
// {
10+
// gateway: process.env.NEXT_PUBLIC_ORBIS_NODE_URL || '',
11+
// env: process.env.NEXT_PUBLIC_ORBIS_ENV || ''
12+
// }
13+
// ]
14+
// })
1515

16-
const data = {
17-
contexts: {
18-
plurality: process.env.NEXT_PUBLIC_PLURALITY_CONTEXT,
19-
},
20-
models: {
21-
test_model: process.env.NEXT_PUBLIC_TEST_MODEL,
22-
profile_type_model: process.env.NEXT_PUBLIC_PROFILE_TYPE_MODEL
23-
}
24-
}
16+
// const data = {
17+
// contexts: {
18+
// plurality: process.env.NEXT_PUBLIC_PLURALITY_CONTEXT,
19+
// },
20+
// models: {
21+
// test_model: process.env.NEXT_PUBLIC_TEST_MODEL,
22+
// profile_type_model: process.env.NEXT_PUBLIC_PROFILE_TYPE_MODEL
23+
// }
24+
// }
2525

26-
export async function selectProfileType1(stream_id: string) {
27-
try {
28-
let selectStatement = await orbisdb.select().from(data.models.profile_type_model || '')
29-
.where({
30-
stream_id: stream_id
31-
})
32-
.context(process.env.NEXT_PUBLIC_PLURALITY_CONTEXT || '');
33-
// const query = selectStatement.build()
34-
// console.log("Query that will be run", query)
35-
const result= await selectStatement.run();
36-
// console.log("Result", result)
37-
// console.log(result);
38-
// columns: Array<string>
39-
// rows: Array<T | Record<string, any>>
40-
const { columns, rows } = result
41-
// console.log({ columns, rows });
42-
return { columns, rows };
43-
}
44-
catch (error) {
45-
console.log("Error", error)
46-
}
47-
}
26+
// export async function selectProfileType1(stream_id: string) {
27+
// try {
28+
// let selectStatement = await orbisdb.select().from(data.models.profile_type_model || '')
29+
// .where({
30+
// stream_id: stream_id
31+
// })
32+
// .context(process.env.NEXT_PUBLIC_PLURALITY_CONTEXT || '');
33+
// // const query = selectStatement.build()
34+
// // console.log("Query that will be run", query)
35+
// const result= await selectStatement.run();
36+
// // console.log("Result", result)
37+
// // console.log(result);
38+
// // columns: Array<string>
39+
// // rows: Array<T | Record<string, any>>
40+
// const { columns, rows } = result
41+
// // console.log({ columns, rows });
42+
// return { columns, rows };
43+
// }
44+
// catch (error) {
45+
// console.log("Error", error)
46+
// }
47+
// }
4848

4949

5050
export async function selectProfileType(stream_id: string) {

0 commit comments

Comments
 (0)