mirror of
https://github.com/status-im/consul.git
synced 2025-01-25 13:10:32 +00:00
9d21736e9f
* Add copyright headers to UI files * Ensure copywrite file ignores external libs
14 lines
358 B
JavaScript
14 lines
358 B
JavaScript
/**
|
|
* Copyright (c) HashiCorp, Inc.
|
|
* SPDX-License-Identifier: MPL-2.0
|
|
*/
|
|
|
|
import { helper } from '@ember/component/helper';
|
|
|
|
export default helper(function flattenProperty([obj, prop], hash) {
|
|
const pages = hash.pages || [];
|
|
pages.push(...obj.pages);
|
|
obj.children.forEach((child) => flattenProperty([child], { pages: pages }));
|
|
return pages;
|
|
});
|