Fixed the bug but there are still another bugs