Skip to content

Commit d9486ad

Browse files
committed
fix: add unique representation for multiple plugin instances
1 parent 1e8ebdf commit d9486ad

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

index.ts

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -37,18 +37,6 @@ export default class extends AdminForthPlugin {
3737
instanceUniqueRepresentation(pluginOptions: any) : string {
3838
// optional method to return unique string representation of plugin instance.
3939
// Needed if plugin can have multiple instances on one resource
40-
return `single`;
40+
return `${this.resourceConfig.resourceId}-clone-row`;
4141
}
42-
43-
setupEndpoints(server: IHttpServer) {
44-
server.endpoint({
45-
method: 'POST',
46-
path: `/plugin/${this.pluginInstanceId}/example`,
47-
handler: async ({ body }) => {
48-
const { name } = body;
49-
return { hey: `Hello ${name}` };
50-
}
51-
});
52-
}
53-
5442
}

0 commit comments

Comments
 (0)