Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
drupal
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
drupal
Commits
6b0756e2
Commit
6b0756e2
authored
11 years ago
by
Angie Byron
Browse files
Options
Downloads
Patches
Plain Diff
Issue
#2190695
by alexpott: Remove unnecessary update functions.
parent
3ae319e4
Branches
Branches containing commit
Tags
Tags containing commit
2 merge requests
!7452
Issue #1797438. HTML5 validation is preventing form submit and not fully...
,
!789
Issue #3210310: Adjust Database API to remove deprecated Drupal 9 code in Drupal 10
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
core/includes/update.inc
+0
-57
0 additions, 57 deletions
core/includes/update.inc
with
0 additions
and
57 deletions
core/includes/update.inc
+
0
−
57
View file @
6b0756e2
...
...
@@ -768,63 +768,6 @@ function update_retrieve_dependencies() {
return
$return
;
}
/**
* Helper function to update entities with uuid.
*
* @param array $sandbox
* A sandbox where conversion happens.
* @param string $table
* A table whose data should be updated.
* @param string $primary_key
* A $table primary key column.
* @param array $values
* A $primary_key values of rows to be updated.
*/
function
update_add_uuids
(
&
$sandbox
,
$table
,
$primary_key
,
$values
)
{
$uuid
=
\Drupal
::
service
(
'uuid'
);
foreach
(
$values
as
$value
)
{
db_update
(
$table
)
->
fields
(
array
(
'uuid'
=>
$uuid
->
generate
(),
))
->
condition
(
$primary_key
,
$value
)
->
isNull
(
'uuid'
)
->
execute
();
$sandbox
[
'progress'
]
++
;
$sandbox
[
'last'
]
=
$value
;
}
}
/**
* Adds tags, checksum_invalidations, checksum_deletions to a cache table.
*
* @param string $table
* Name of the cache table.
*/
function
update_add_cache_columns
(
$table
)
{
if
(
db_table_exists
(
$table
)
&&
!
db_field_exists
(
$table
,
'tags'
))
{
db_add_field
(
$table
,
'tags'
,
array
(
'description'
=>
'Space-separated list of cache tags for this entry.'
,
'type'
=>
'text'
,
'size'
=>
'big'
,
'not null'
=>
FALSE
,
));
db_add_field
(
$table
,
'checksum_invalidations'
,
array
(
'description'
=>
'The tag invalidation sum when this entry was saved.'
,
'type'
=>
'int'
,
'not null'
=>
TRUE
,
'default'
=>
0
,
));
db_add_field
(
$table
,
'checksum_deletions'
,
array
(
'description'
=>
'The tag deletion sum when this entry was saved.'
,
'type'
=>
'int'
,
'not null'
=>
TRUE
,
'default'
=>
0
,
));
}
}
/**
* Replace permissions during update.
*
...
...
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