Tried to fix sample construnction bug