mirror of
https://github.com/discourse/discourse.git
synced 2025-06-03 19:39:30 +08:00
DEV: apply new coding standards (#10592)
This commit is contained in:
@ -1,14 +1,14 @@
|
||||
export default function(helpers) {
|
||||
export default function (helpers) {
|
||||
const { response } = helpers;
|
||||
const fixturesByUrl = {};
|
||||
|
||||
// Load any fixtures automatically
|
||||
Object.keys(require._eak_seen).forEach(entry => {
|
||||
Object.keys(require._eak_seen).forEach((entry) => {
|
||||
if (/^fixtures/.test(entry)) {
|
||||
const fixture = require(entry, null, null, true);
|
||||
if (fixture && fixture.default) {
|
||||
const obj = fixture.default;
|
||||
Object.keys(obj).forEach(url => {
|
||||
Object.keys(obj).forEach((url) => {
|
||||
fixturesByUrl[url] = obj[url];
|
||||
this.get(url, () => response(obj[url]));
|
||||
});
|
||||
|
Reference in New Issue
Block a user