@crowdin/app-project-module 0.51.0 → 0.51.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.
- package/out/index.js +5 -1
- package/package.json +1 -1
package/out/index.js
CHANGED
|
@@ -188,8 +188,12 @@ function addCrowdinEndpoints(app, clientConfig) {
|
|
|
188
188
|
exports.addCrowdinEndpoints = addCrowdinEndpoints;
|
|
189
189
|
function addFormSchema({ app, config }) {
|
|
190
190
|
if (Object.keys(config).some((moduleKey) => {
|
|
191
|
+
var _a;
|
|
191
192
|
const moduleConfig = config[moduleKey];
|
|
192
|
-
|
|
193
|
+
if (typeof moduleConfig === 'object' && moduleConfig !== null) {
|
|
194
|
+
return ('formSchema' in moduleConfig ||
|
|
195
|
+
('settingsUiModule' in moduleConfig && ((_a = moduleConfig.settingsUiModule) === null || _a === void 0 ? void 0 : _a.formSchema)));
|
|
196
|
+
}
|
|
193
197
|
})) {
|
|
194
198
|
app.get('/api/form-data', json_response_1.default, (0, crowdin_client_1.default)(config), (0, form_data_display_1.default)());
|
|
195
199
|
app.post('/api/form-data', (0, crowdin_client_1.default)(config), (0, form_data_save_1.default)());
|
package/package.json
CHANGED