Fixes detached persistency bug

closes #209