@appconda/nextjs 1.0.24 → 1.0.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,6 +4,12 @@ import { getSDKForCurrentUser } from '../getSDKForCurrentUser';
4
4
  export const getAllNodesAction = actionClient
5
5
  // .schema(listModelsSchema)
6
6
  .action(async ({ parsedInput }) => {
7
- const { node } = await getSDKForCurrentUser();
8
- return await node.GetAllNodes();
7
+ try {
8
+ const { node } = await getSDKForCurrentUser();
9
+ return await node.GetAllNodes();
10
+ }
11
+ catch (error) {
12
+ console.error('Error in getAllNodesAction:', error);
13
+ throw new Error('Failed to fetch nodes');
14
+ }
9
15
  });
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@appconda/nextjs",
3
3
  "homepage": "https://appconda.io/support",
4
4
  "description": "Appconda is an open-source self-hosted backend server that abstract and simplify complex and repetitive development tasks behind a very simple REST API",
5
- "version": "1.0.24",
5
+ "version": "1.0.25",
6
6
  "license": "BSD-3-Clause",
7
7
  "main": "dist/index.js",
8
8
  "types": "dist/index.d.ts",
@@ -30,7 +30,9 @@
30
30
  "next": "^15.2.3",
31
31
  "next-safe-action": "^7.10.4",
32
32
  "node-fetch-native-with-agent": "^1.7.2",
33
- "redis": "^4.7.0",
34
33
  "zod": "^3.24.2"
34
+ },
35
+ "peerDependencies": {
36
+ "redis": "^4.7.0"
35
37
  }
36
38
  }
@@ -7,6 +7,11 @@ import { getSDKForCurrentUser } from '../getSDKForCurrentUser';
7
7
  export const getAllNodesAction = actionClient
8
8
  // .schema(listModelsSchema)
9
9
  .action(async ({ parsedInput }) => {
10
- const { node } = await getSDKForCurrentUser();
11
- return await node.GetAllNodes();
10
+ try {
11
+ const { node } = await getSDKForCurrentUser();
12
+ return await node.GetAllNodes();
13
+ } catch (error) {
14
+ console.error('Error in getAllNodesAction:', error);
15
+ throw new Error('Failed to fetch nodes');
16
+ }
12
17
  });
package/rollup.config.js DELETED
@@ -1,27 +0,0 @@
1
- import pkg from "./package.json";
2
- import typescript from "@rollup/plugin-typescript";
3
-
4
- export default {
5
- external: Object.keys(pkg.dependencies ?? {}),
6
- input: "src/index.ts",
7
- plugins: [typescript()],
8
- output: [
9
- {
10
- format: "cjs",
11
- file: pkg.main,
12
- esModule: false,
13
- sourcemap: true,
14
- },
15
- {
16
- format: "es",
17
- file: pkg.module,
18
- sourcemap: true,
19
- },
20
- {
21
- format: "iife",
22
- file: pkg.jsdelivr,
23
- name: "Appconda",
24
- extend: true,
25
- },
26
- ],
27
- };