@@ -32,7 +32,7 @@ public class AccountResource {
3232 @ POST
3333 @ Consumes (MediaType .APPLICATION_JSON )
3434 @ Produces (MediaType .APPLICATION_JSON )
35- @ Path ("/account- hooks" )
35+ @ Path ("/account/ hooks" )
3636 public Response accountHooks (@ Context SecurityIdentity identity ,
3737 AccountHookRequest request ) {
3838
@@ -76,27 +76,38 @@ public Response exportExampleScreener(@Context SecurityIdentity identity) {
7676
7777 if (userId == null ) {
7878 return Response .status (Response .Status .UNAUTHORIZED )
79- .entity (new ApiError (true , "Unauthorized." )).build ();
79+ .entity (new ApiError (true , "Unauthorized." )).build ();
8080 }
8181
8282 if (LaunchMode .current () != LaunchMode .DEVELOPMENT ) {
8383 return Response .status (Response .Status .NOT_FOUND ).build ();
8484 }
8585
8686 try {
87- ExampleScreenerExportService .ExportSummary summary = exampleScreenerExportService .exportForUser (userId );
88- return Response .ok (Map .of (
89- "success" , true ,
90- "outputPath" , summary .outputPath (),
91- "screenerCount" , summary .screenerCount (),
92- "firestoreDocuments" , summary .firestoreDocuments (),
93- "storageFiles" , summary .storageFiles ()
94- )).build ();
87+ ExampleScreenerExportService .ExportSummary summary = exampleScreenerExportService
88+ .exportForUser (userId );
89+ return Response .ok (
90+ Map .of (
91+ "success" ,
92+ true ,
93+ "outputPath" ,
94+ summary .outputPath (),
95+ "screenerCount" ,
96+ summary .screenerCount (),
97+ "firestoreDocuments" ,
98+ summary .firestoreDocuments (),
99+ "storageFiles" ,
100+ summary .storageFiles ()))
101+ .build ();
95102 } catch (Exception e ) {
96- Log .error ("Failed to export example screener seed data for user " + userId , e );
97- return Response .serverError ()
98- .entity (new ApiError (true , "Failed to export example screener seed data." ))
99- .build ();
103+ Log .error (
104+ "Failed to export example screener seed data for user "
105+ + userId ,
106+ e );
107+ return Response .serverError ().entity (
108+ new ApiError (true ,
109+ "Failed to export example screener seed data." ))
110+ .build ();
100111 }
101112 }
102113}
0 commit comments