merging a working version