mirror of
https://github.com/strapi/strapi.git
synced 2025-09-21 14:31:16 +00:00
Ensure we are on plugin or admin URLs
This commit is contained in:
parent
69e4313abe
commit
51af99b31a
@ -6,7 +6,7 @@ const { parallel } = require('async');
|
|||||||
const { after, includes, indexOf, drop, dropRight, uniq, defaultsDeep, get, set, isEmpty, isUndefined, union } = require('lodash');
|
const { after, includes, indexOf, drop, dropRight, uniq, defaultsDeep, get, set, isEmpty, isUndefined, union } = require('lodash');
|
||||||
|
|
||||||
module.exports = function() {
|
module.exports = function() {
|
||||||
const accepted = Object.keys(this.plugins).map(url => `^\/${url}`).concat(['^\/admin']);
|
const accepted = Object.keys(this.plugins).map(url => `^\/${url}/`).concat(['^\/admin/']);
|
||||||
|
|
||||||
// Set if is admin destination for middleware application.
|
// Set if is admin destination for middleware application.
|
||||||
// TODO: Use dynamic config for admin url.
|
// TODO: Use dynamic config for admin url.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user