From 7cf7f998781c24f0f27218a9ffdcde290e7ec6ec Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sun, 20 Sep 2009 07:32:19 +0000 Subject: =?UTF-8?q?-=20Patch=20#11218=20by=20David=5FRothstein,=20sun,=20q?= =?UTF-8?q?uicksketch,=20duncf,=20awood456,=20dropcube,=20mgifford=20|=20p?= =?UTF-8?q?wolanin,=20dww,=20RobRoy,=20Crell,=20webchick,=20beginner,=20ra?= =?UTF-8?q?y007,=20bjaspan,=20chx,=20G=C3=A1bor=20Hojtsy,=20Steven,=20Drie?= =?UTF-8?q?s,=20lutegrass,=20sym,=20guardian,=20matt2000,=20geerlingguy,?= =?UTF-8?q?=20SeanBannister,=20matt=20westgate,=20com2,=20praseodym:=20all?= =?UTF-8?q?ow=20default=20text=20formats=20per=20role,=20and=20integrate?= =?UTF-8?q?=20text=20format=20permissions.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/node/node.install | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'modules/node/node.install') diff --git a/modules/node/node.install b/modules/node/node.install index c53bdf8c9..6ac772029 100644 --- a/modules/node/node.install +++ b/modules/node/node.install @@ -506,7 +506,11 @@ function node_update_7006(&$context) { $revision->body = substr($revision->body, strlen($break)); } $node->body[FIELD_LANGUAGE_NONE][0]['value'] = $revision->body; - $node->body[FIELD_LANGUAGE_NONE][0]['format'] = $revision->format; + // Explicitly store the current default text format if the revision + // did not have its own text format. Similar conversions for other + // core modules are performed in filter_update_7005(), but we do this + // one here since we are already migrating the data. + $node->body[FIELD_LANGUAGE_NONE][0]['format'] = !empty($revision->format) ? $revision->format : variable_get('filter_default_format', 1); // This is a core update and no contrib modules are enabled yet, so // we can assume default field storage for a faster update. field_sql_storage_field_storage_write('node', $node, FIELD_STORAGE_INSERT, array()); -- cgit v1.2.3