Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix Eru "Pod Resource" function returned duplicated #544 #546

Merged
merged 1 commit into from
Jan 26, 2022

Conversation

giaosame
Copy link
Contributor

No description provided.

Copy link
Member

@jschwinger233 jschwinger233 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

另一种改法是用闭包把循环变量固化

@giaosame
Copy link
Contributor Author

是的。或者直接给goroutine所要运行的那个函数设置对应的参数,将node.name作为参数传给这个异步函数,传进去的参数就是局部变量而不会出现上述情况了。

@jschwinger233 jschwinger233 linked an issue Jan 26, 2022 that may be closed by this pull request
@CMGS CMGS merged commit 4fbc369 into projecteru2:master Jan 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Eru "Pod Resource" function returned duplicated
3 participants