mirror of
https://github.com/hcengineering/platform.git
synced 2024-12-24 12:06:57 +03:00
Fix Hierarchy is extends is not working second time
Fix Hierarchy is extends is not working second time Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
parent
32d559a07b
commit
1dd945d7b3
@ -165,7 +165,7 @@ export class Hierarchy {
|
|||||||
*/
|
*/
|
||||||
private isExtends<T extends Doc>(extendsOrImplements: Ref<Interface<Doc>>[], from: Ref<Interface<T>>): boolean {
|
private isExtends<T extends Doc>(extendsOrImplements: Ref<Interface<Doc>>[], from: Ref<Interface<T>>): boolean {
|
||||||
const result: Ref<Interface<Doc>>[] = []
|
const result: Ref<Interface<Doc>>[] = []
|
||||||
const toVisit = extendsOrImplements
|
const toVisit = [...extendsOrImplements]
|
||||||
while (toVisit.length > 0) {
|
while (toVisit.length > 0) {
|
||||||
const ref = toVisit.shift() as Ref<Interface<Doc>>
|
const ref = toVisit.shift() as Ref<Interface<Doc>>
|
||||||
if (ref === from) {
|
if (ref === from) {
|
||||||
|
Loading…
Reference in New Issue
Block a user