updated for compatibility with simplified DB