Fixed the bug in struct