@mohasinac/appkit 3.5.0 → 3.5.1
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.
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
* is marked failed so an admin can retry.
|
|
18
18
|
*/
|
|
19
19
|
import { normalizeError } from "../../../../errors/normalize";
|
|
20
|
-
import { userRepository, sessionRepository, storeRepository, productRepository, bidRepository, addressesRepository, savedPaymentMethodsRepository, } from "../../../../repositories";
|
|
20
|
+
import { userRepository, sessionRepository, storeRepository, productRepository, bidRepository, addressesRepository, savedPaymentMethodsRepository, siteSettingsRepository, } from "../../../../repositories";
|
|
21
21
|
import { sendNotification } from "../../../../features/admin/actions/notification-actions";
|
|
22
22
|
import { isSellerUser } from "../../../../features/auth/role-predicates";
|
|
23
23
|
import { getAdminAuth } from "../../../../providers/db-firebase";
|
|
@@ -153,12 +153,14 @@ export async function runHardBanCascade(input, ctx) {
|
|
|
153
153
|
}
|
|
154
154
|
// 8. Notify user
|
|
155
155
|
try {
|
|
156
|
+
const siteSettings = await siteSettingsRepository.getSingleton();
|
|
157
|
+
const supportEmail = siteSettings.contact?.email || "support@example.com";
|
|
156
158
|
await sendNotification({
|
|
157
159
|
userId: uid,
|
|
158
160
|
type: "account_action",
|
|
159
161
|
priority: "high",
|
|
160
162
|
title: "Account permanently suspended",
|
|
161
|
-
message: `Your account has been permanently suspended. Reason: ${reason}. You may appeal by emailing
|
|
163
|
+
message: `Your account has been permanently suspended. Reason: ${reason}. You may appeal by emailing ${supportEmail}.`,
|
|
162
164
|
relatedId: uid,
|
|
163
165
|
relatedType: "user",
|
|
164
166
|
});
|