naystack 1.5.2 → 1.5.3
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.
- package/dist/graphql/index.cjs.js +16 -20
- package/dist/graphql/index.esm.js +16 -20
- package/dist/graphql/utils.cjs.js +16 -20
- package/dist/graphql/utils.esm.js +16 -20
- package/package.json +1 -1
|
@@ -733,28 +733,24 @@ var getUserId = async () => {
|
|
|
733
733
|
return refresh ? getUserIdFromRefreshToken(refresh) : null;
|
|
734
734
|
};
|
|
735
735
|
function getAuthCaller(fn) {
|
|
736
|
-
return (
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
}
|
|
745
|
-
);
|
|
736
|
+
return async (data) => {
|
|
737
|
+
"use server";
|
|
738
|
+
const ctx = {
|
|
739
|
+
userId: await getUserId(),
|
|
740
|
+
isRefreshID: true
|
|
741
|
+
};
|
|
742
|
+
return await fn(ctx, data);
|
|
743
|
+
};
|
|
746
744
|
}
|
|
747
745
|
function getCaller(fn) {
|
|
748
|
-
return (
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
}
|
|
757
|
-
);
|
|
746
|
+
return async (data) => {
|
|
747
|
+
"use server";
|
|
748
|
+
const ctx = {
|
|
749
|
+
userId: null,
|
|
750
|
+
isRefreshID: true
|
|
751
|
+
};
|
|
752
|
+
return await fn(ctx, data);
|
|
753
|
+
};
|
|
758
754
|
}
|
|
759
755
|
function getFieldAuthCaller(fn) {
|
|
760
756
|
return (0, import_react.cache)(
|
|
@@ -729,28 +729,24 @@ var getUserId = async () => {
|
|
|
729
729
|
return refresh ? getUserIdFromRefreshToken(refresh) : null;
|
|
730
730
|
};
|
|
731
731
|
function getAuthCaller(fn) {
|
|
732
|
-
return
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
}
|
|
741
|
-
);
|
|
732
|
+
return async (data) => {
|
|
733
|
+
"use server";
|
|
734
|
+
const ctx = {
|
|
735
|
+
userId: await getUserId(),
|
|
736
|
+
isRefreshID: true
|
|
737
|
+
};
|
|
738
|
+
return await fn(ctx, data);
|
|
739
|
+
};
|
|
742
740
|
}
|
|
743
741
|
function getCaller(fn) {
|
|
744
|
-
return
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
}
|
|
753
|
-
);
|
|
742
|
+
return async (data) => {
|
|
743
|
+
"use server";
|
|
744
|
+
const ctx = {
|
|
745
|
+
userId: null,
|
|
746
|
+
isRefreshID: true
|
|
747
|
+
};
|
|
748
|
+
return await fn(ctx, data);
|
|
749
|
+
};
|
|
754
750
|
}
|
|
755
751
|
function getFieldAuthCaller(fn) {
|
|
756
752
|
return cache(
|
|
@@ -126,28 +126,24 @@ var getUserId = async () => {
|
|
|
126
126
|
return refresh ? getUserIdFromRefreshToken(refresh) : null;
|
|
127
127
|
};
|
|
128
128
|
function getAuthCaller(fn) {
|
|
129
|
-
return (
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
}
|
|
138
|
-
);
|
|
129
|
+
return async (data) => {
|
|
130
|
+
"use server";
|
|
131
|
+
const ctx = {
|
|
132
|
+
userId: await getUserId(),
|
|
133
|
+
isRefreshID: true
|
|
134
|
+
};
|
|
135
|
+
return await fn(ctx, data);
|
|
136
|
+
};
|
|
139
137
|
}
|
|
140
138
|
function getCaller(fn) {
|
|
141
|
-
return (
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
}
|
|
150
|
-
);
|
|
139
|
+
return async (data) => {
|
|
140
|
+
"use server";
|
|
141
|
+
const ctx = {
|
|
142
|
+
userId: null,
|
|
143
|
+
isRefreshID: true
|
|
144
|
+
};
|
|
145
|
+
return await fn(ctx, data);
|
|
146
|
+
};
|
|
151
147
|
}
|
|
152
148
|
function getFieldAuthCaller(fn) {
|
|
153
149
|
return (0, import_react.cache)(
|
|
@@ -111,28 +111,24 @@ var getUserId = async () => {
|
|
|
111
111
|
return refresh ? getUserIdFromRefreshToken(refresh) : null;
|
|
112
112
|
};
|
|
113
113
|
function getAuthCaller(fn) {
|
|
114
|
-
return
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
}
|
|
123
|
-
);
|
|
114
|
+
return async (data) => {
|
|
115
|
+
"use server";
|
|
116
|
+
const ctx = {
|
|
117
|
+
userId: await getUserId(),
|
|
118
|
+
isRefreshID: true
|
|
119
|
+
};
|
|
120
|
+
return await fn(ctx, data);
|
|
121
|
+
};
|
|
124
122
|
}
|
|
125
123
|
function getCaller(fn) {
|
|
126
|
-
return
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
135
|
-
);
|
|
124
|
+
return async (data) => {
|
|
125
|
+
"use server";
|
|
126
|
+
const ctx = {
|
|
127
|
+
userId: null,
|
|
128
|
+
isRefreshID: true
|
|
129
|
+
};
|
|
130
|
+
return await fn(ctx, data);
|
|
131
|
+
};
|
|
136
132
|
}
|
|
137
133
|
function getFieldAuthCaller(fn) {
|
|
138
134
|
return cache(
|