Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
module_cleanup
Manage
Activity
Members
Labels
Plan
Wiki
Custom issue tracker
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
module_cleanup
Merge requests
!6
Clear Updates.
Code
Review changes
Check out branch
Open in Workspace
Download
Patches
Plain diff
Expand sidebar
Merged
Clear Updates.
drush-clear-updates
into
1.0.x
Overview
0
Commits
1
Pipelines
0
Changes
1
Merged
Clear Updates.
Trigve Hagen
requested to merge
drush-clear-updates
into
1.0.x
4 months ago
Overview
0
Commits
1
Pipelines
0
Changes
1
0
0
Merge request reports
Compare
1.0.x
1.0.x (base)
and
latest version
latest version
2a306c6a
1 commit,
4 months ago
1 file
+
18
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
src/Commands/ModuleCleanupDrushCommands.php
+
18
−
0
View file @ 2a306c6a
Edit in single-file editor
Open in Web IDE
Show full file
@@ -137,6 +137,24 @@ class ModuleCleanupDrushCommands extends DrushCommands {
}
}
/**
* Cleans up No available releases found errors in Available updates.
*
* @command modcup:clear-updates
* @aliases modcup-cu
* @usage modcup-cu
*/
public
function
clearUpdates
()
{
// Clears errors in Available updates.
if
(
$this
->
database
->
delete
(
'key_value'
)
->
condition
(
'collection'
,
'update_fetch_task'
)
->
execute
())
{
$this
->
logger
()
->
success
(
$this
->
t
(
'Avalable updates restored.'
));
}
else
{
$this
->
logger
()
->
error
(
$this
->
t
(
'Clear updates failed to execute.'
));
return
self
::
EXIT_ERROR
;
}
}
/**
* Deletes data from a module left over in the config table.
*
Loading