fix bug in Chris' work and refactord another version