fixed a problem where it added nulls