ensures that getClaimIdByLongChannelId tests for bidstate #770

Merged
jessopb merged 1 commit from fix741 into master 2018-11-30 03:28:07 +01:00
2 changed files with 2 additions and 2 deletions

View file

@ -917,7 +917,7 @@ var claimQueries = (db, table, sequelize) => ({
getClaimIdByLongChannelId: async (channelClaimId, claimName) => {
logger$1.debug(`finding claim id for claim ${claimName} from channel ${channelClaimId}`);
return await table.findAll({
where: { name: claimName, publisher_id: channelClaimId },
where: { name: claimName, publisher_id: channelClaimId, bid_state: { [sequelize.Op.or]: ['Controlling', 'Active', 'Accepted'] } },
order: [['id', 'ASC']],
})
.then(result => {

View file

@ -116,7 +116,7 @@ export default (db, table, sequelize) => ({
getClaimIdByLongChannelId: async (channelClaimId, claimName) => {
logger.debug(`finding claim id for claim ${claimName} from channel ${channelClaimId}`);
return await table.findAll({
where: { name: claimName, publisher_id: channelClaimId },
where: { name: claimName, publisher_id: channelClaimId, bid_state: { [sequelize.Op.or]: ['Controlling', 'Active', 'Accepted'] } },
order: [['id', 'ASC']],
})
.then(result => {