$count,
'1 pending update (@number_applied to be applied, @number_incompatible skipped)',
'@count pending updates (@number_applied to be applied, @number_incompatible skipped)',
['@number_applied' =>
$count -
$incompatible_count, '@number_incompatible' =>
$incompatible_count] );
} else { $build['start'
]['#title'
] =
$this->
formatPlural($count, '1 pending update', '@count pending updates'
);
} // @todo Simplify with https://www.drupal.org/node/2548095
$base_url =
str_replace('/update.php', '',
$request->
getBaseUrl());
$url =
(new Url('system.db_update',
['op' => 'run'
]))->
setOption('base_url',
$base_url);
$build['link'
] =
[ '#type' => 'link',
'#title' =>
$this->
t('Apply pending updates'
),
'#attributes' =>
['class' =>
['button', 'button--primary'
]],
'#weight' => 5,
'#url' =>
$url,
'#access' =>
$url->
access($this->
currentUser()),
];
} return $build;
}