fixed the obvious bug