change DB to singleton