mirror of
https://github.com/strapi/strapi.git
synced 2025-12-24 13:43:41 +00:00
Merge branch 'master' into master
This commit is contained in:
commit
0f34541231
@ -90,7 +90,7 @@ module.exports = {
|
||||
//...
|
||||
settings: {
|
||||
cors: {
|
||||
origin: 'http://localhost',
|
||||
origin: ['http://localhost', 'https://mysite.com', 'https://www.mysite.com']
|
||||
},
|
||||
},
|
||||
};
|
||||
@ -207,7 +207,7 @@ The session doesn't work with `mongo` as a client. The package that we should us
|
||||
- `enabled` (boolean): Enable or disable XSS to prevent Cross Site Scripting (XSS) attacks in older IE browsers (IE8).
|
||||
- [`cors`](https://en.wikipedia.org/wiki/Cross-origin_resource_sharing)
|
||||
- `enabled` (boolean): Enable or disable CORS to prevent your server to be requested from another domain.
|
||||
- `origin` (string): Allowed URLs (`http://example1.com, http://example2.com` or allows everyone `*`). Default value: `*`.
|
||||
- `origin` (string or array): Allowed URLs (`http://example1.com, http://example2.com`, `['http://www.example1.com', 'http://example1.com']` or allows everyone `*`). Default value: `*`.
|
||||
- `expose` (array): Configures the `Access-Control-Expose-Headers` CORS header. If not specified, no custom headers are exposed. Default value: `["WWW-Authenticate", "Server-Authorization"]`.
|
||||
- `maxAge` (integer): Configures the `Access-Control-Max-Age` CORS header. Default value: `31536000`.
|
||||
- `credentials` (boolean): Configures the `Access-Control-Allow-Credentials` CORS header. Default value: `true`.
|
||||
|
||||
@ -44,7 +44,7 @@ const emailTemplate = {
|
||||
Your account is now linked with: <%= user.email %>.`,
|
||||
html: `<h1>Welcome on mywebsite.fr!</h1>
|
||||
<p>Your account is now linked with: <%= user.email %>.<p>`,
|
||||
},
|
||||
};
|
||||
|
||||
await strapi.plugins.email.services.email.sendTemplatedEmail(
|
||||
{
|
||||
|
||||
@ -212,7 +212,7 @@ const createAggregationFieldsResolver = function(model, fields, operation, typeC
|
||||
* Correctly format the data returned by the group by
|
||||
*/
|
||||
const preProcessGroupByData = function({ result, fieldKey, filters }) {
|
||||
const _result = _.toArray(result);
|
||||
const _result = _.toArray(result).filter(value => Boolean(value._id));
|
||||
return _.map(_result, value => {
|
||||
return {
|
||||
key: value._id.toString(),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user