Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
N
node_revision_delete
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
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
project
node_revision_delete
Commits
7e8cfa2f
Commit
7e8cfa2f
authored
2 years ago
by
Adrian Cid Almaguer
Committed by
Adrian Cid Almaguer
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#3300778
by adriancid: Delete unnedeed validations for drush commands
parent
31116de4
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/Commands/NodeRevisionDeleteCommands.php
+0
-15
0 additions, 15 deletions
src/Commands/NodeRevisionDeleteCommands.php
with
0 additions
and
15 deletions
src/Commands/NodeRevisionDeleteCommands.php
+
0
−
15
View file @
7e8cfa2f
...
@@ -186,8 +186,6 @@ class NodeRevisionDeleteCommands extends DrushCommands {
...
@@ -186,8 +186,6 @@ class NodeRevisionDeleteCommands extends DrushCommands {
*
*
* @command nrd:set-time
* @command nrd:set-time
* @aliases nrd-st, nrd-set-time
* @aliases nrd-st, nrd-set-time
*
* @throws \Drush\Exceptions\UserAbortException
*/
*/
public
function
setTime
(
string
$time
=
''
):
void
{
public
function
setTime
(
string
$time
=
''
):
void
{
// Getting an editable config because we will get and set a value.
// Getting an editable config because we will get and set a value.
...
@@ -425,19 +423,6 @@ class NodeRevisionDeleteCommands extends DrushCommands {
...
@@ -425,19 +423,6 @@ class NodeRevisionDeleteCommands extends DrushCommands {
public
function
deletePriorRevisionsValidate
(
CommandData
$commandData
):
bool
{
public
function
deletePriorRevisionsValidate
(
CommandData
$commandData
):
bool
{
$input
=
$commandData
->
input
();
$input
=
$commandData
->
input
();
$nid
=
$input
->
getArgument
(
'nid'
);
$nid
=
$input
->
getArgument
(
'nid'
);
$vid
=
$input
->
getArgument
(
'vid'
);
// Nid argument must be numeric.
if
(
!
is_numeric
(
$nid
))
{
$this
->
io
()
->
error
(
dt
(
'Argument nid must be numeric.'
));
return
FALSE
;
}
// Vid argument must be numeric.
if
(
!
is_numeric
(
$vid
))
{
$this
->
io
()
->
error
(
dt
(
'Argument vid must be numeric.'
));
return
FALSE
;
}
// Check if argument nid is a valid node id.
// Check if argument nid is a valid node id.
$node
=
$this
->
entityTypeManager
->
getStorage
(
'node'
)
->
load
(
$nid
);
$node
=
$this
->
entityTypeManager
->
getStorage
(
'node'
)
->
load
(
$nid
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment