mirror of
https://github.com/strapi/strapi.git
synced 2025-09-25 16:29:34 +00:00
Merge branch 'master' into fix/1785
This commit is contained in:
commit
bff434f3ad
30
.github/ISSUE_TEMPLATE.md
vendored
30
.github/ISSUE_TEMPLATE.md
vendored
@ -1,16 +1,20 @@
|
||||
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
|
||||
|
||||
<!-- ISSUE TEMPLATE -->
|
||||
<!-- =============================================================================== -->
|
||||
<!-- ⚠️ If you are not using the current Strapi release, you will be asked to update. -->
|
||||
<!-- Please see the wiki for guides on upgrading to the latest release. -->
|
||||
<!-- =============================================================================== -->
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
||||
<!-- ⚠️ Before writing your issue make sure you are using:-->
|
||||
<!-- Node 9.x.x -->
|
||||
<!-- npm 5.x.x -->
|
||||
<!-- The latest version of Strapi. -->
|
||||
<!-- Node 10.x.x -->
|
||||
<!-- npm 6.x.x -->
|
||||
|
||||
**Informations**
|
||||
- **Node.js version**:
|
||||
- **npm version**:
|
||||
- **Strapi version**:
|
||||
- **Strapi version**: <!-- Please make sure you are on the latest version -->
|
||||
- **Database**:
|
||||
- **Operating system**:
|
||||
|
||||
@ -28,19 +32,3 @@
|
||||
|
||||
|
||||
**Suggested solutions**
|
||||
|
||||
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
||||
|
||||
|
||||
<!-- FEATURE REQUEST TEMPLATE -->
|
||||
|
||||
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
|
||||
|
||||
**What is the expected behavior?**
|
||||
|
||||
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
18
.github/ISSUE_TEMPLATE/BUG_REPORT.md
vendored
18
.github/ISSUE_TEMPLATE/BUG_REPORT.md
vendored
@ -5,15 +5,21 @@ about: Create a report to help us improve 🤔.
|
||||
|
||||
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
|
||||
|
||||
<!-- =============================================================================== -->
|
||||
<!-- ⚠️ If you are not using the current Strapi release, you will be asked to update. -->
|
||||
<!-- Please see the wiki for guides on upgrading to the latest release. -->
|
||||
<!-- =============================================================================== -->
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
||||
<!-- ⚠️ Before writing your issue make sure you are using:-->
|
||||
<!-- Node 9.x.x -->
|
||||
<!-- npm 5.x.x -->
|
||||
<!-- The latest version of Strapi. -->
|
||||
<!-- Node 10.x.x -->
|
||||
<!-- npm 6.x.x -->
|
||||
|
||||
**Informations**
|
||||
- **Node.js version**:
|
||||
- **npm version**:
|
||||
- **Strapi version**:
|
||||
- **Strapi version**: <!-- Please make sure you are on the latest version -->
|
||||
- **Database**:
|
||||
- **Operating system**:
|
||||
|
||||
@ -31,7 +37,3 @@ about: Create a report to help us improve 🤔.
|
||||
|
||||
|
||||
**Suggested solutions**
|
||||
|
||||
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
4
.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md
vendored
4
.github/ISSUE_TEMPLATE/FEATURE_REQUEST.md
vendored
@ -5,8 +5,8 @@ about: Suggest an idea for this project 💡!
|
||||
|
||||
<!-- ⚠️ If you do not respect this template your issue will be closed. -->
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
||||
**What is the expected behavior?**
|
||||
|
||||
|
||||
|
||||
<!-- ⚠️ Make sure to browse the opened and closed issues before submitting your issue. -->
|
||||
|
0
packages/strapi-generate-new/files/server.js
Normal file → Executable file
0
packages/strapi-generate-new/files/server.js
Normal file → Executable file
@ -1,4 +1,17 @@
|
||||
import { forEach, isObject, isArray, map, mapKeys, includes, reject, isEmpty, findIndex, isUndefined } from 'lodash';
|
||||
import {
|
||||
forEach,
|
||||
isObject,
|
||||
isArray,
|
||||
map,
|
||||
mapKeys,
|
||||
includes,
|
||||
reject,
|
||||
isEmpty,
|
||||
findIndex,
|
||||
isUndefined,
|
||||
isBoolean,
|
||||
isNumber,
|
||||
} from 'lodash';
|
||||
|
||||
/* eslint-disable consistent-return */
|
||||
export function getValidationsFromForm(form, formValidations) {
|
||||
@ -88,7 +101,7 @@ function validate(value, validations) {
|
||||
case 'type':
|
||||
if (validationValue === 'json') {
|
||||
try {
|
||||
if (isObject(value)) {
|
||||
if (isObject(value) || isBoolean(value) || isNumber(value) || isArray(value)) {
|
||||
value = JSON.parse(JSON.stringify(value));
|
||||
} else {
|
||||
errors.push({ id: 'content-manager.error.validation.json' });
|
||||
|
Loading…
x
Reference in New Issue
Block a user