Unverified Commit 2fd02c15 authored by Tamás Nagy's avatar Tamás Nagy
Browse files

Issue #3109216 by bohart: Fatal error: isNotNull should be used instead of condition method

parent f2700eae
Loading
Loading
Loading
Loading
+2 −2
Changes for brightcove.install: 2 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -266,8 +266,8 @@ function brightcove_update_8106() {
function brightcove_update_8107(&$sandbox) {
  // Condition videos which has at least either poster or thumbnail.
  $condition = new Condition('OR');
  $condition->condition('video.poster__target_id', NULL, 'IS NOT')
    ->condition('video.thumbnail__target_id', NULL, 'IS NOT');
  $condition->isNotNull('video.poster__target_id')
    ->isNotNull('video.thumbnail__target_id');

  // Condition for managed files which does not exist.
  $file_condition = new Condition('OR');
+2 −2
Changes for brightcove.module: 2 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@ function _brightcove_initiate_sync() {
    // from Brightcove or not.
    $videos = Database::getConnection()->select('brightcove_video', 'bv')
      ->fields('bv', ['bcvid', 'api_client', 'video_id'])
      ->condition('video_id', NULL, 'IS NOT')
      ->isNotNull('video_id')
      ->execute();
    foreach ($videos as $video) {
      $video_delete_queue->createItem($video);
@@ -107,7 +107,7 @@ function _brightcove_initiate_sync() {
    // from Brightcove or not.
    $playlists = Database::getConnection()->select('brightcove_playlist', 'bv')
      ->fields('bv', ['bcplid', 'api_client', 'playlist_id'])
      ->condition('playlist_id', NULL, 'IS NOT')
      ->isNotNull('playlist_id')
      ->execute();
    foreach ($playlists as $playlist) {
      $playlist_delete_queue->createItem($playlist);