fix `add-sample-data.js` problem with database connection