fixed databag bug, reviewed test