fixed code to list properly