tried to fix a bug.. still buggy