Issue #2857789 by vegantriathlete, snte, narnua, xjm, lauriii: Correct spelling/non-standard use of "therefor"
parent
5c214594ce
commit
6ffadcb913
|
@ -19,7 +19,7 @@ class Standard extends Xss implements EditorXssFilterInterface {
|
||||||
// Apply XSS filtering, but blacklist the <script>, <style>, <link>, <embed>
|
// Apply XSS filtering, but blacklist the <script>, <style>, <link>, <embed>
|
||||||
// and <object> tags.
|
// and <object> tags.
|
||||||
// The <script> and <style> tags are blacklisted because their contents
|
// The <script> and <style> tags are blacklisted because their contents
|
||||||
// can be malicious (and therefor they are inherently unsafe), whereas for
|
// can be malicious (and therefore they are inherently unsafe), whereas for
|
||||||
// all other tags, only their attributes can make them malicious. Since
|
// all other tags, only their attributes can make them malicious. Since
|
||||||
// \Drupal\Component\Utility\Xss::filter() protects against malicious
|
// \Drupal\Component\Utility\Xss::filter() protects against malicious
|
||||||
// attributes, we take no blacklisting action.
|
// attributes, we take no blacklisting action.
|
||||||
|
@ -41,10 +41,10 @@ class Standard extends Xss implements EditorXssFilterInterface {
|
||||||
// also user frustration: what if a text format is configured to allow
|
// also user frustration: what if a text format is configured to allow
|
||||||
// <embed>, for example? Then we would strip that tag, even though it is
|
// <embed>, for example? Then we would strip that tag, even though it is
|
||||||
// allowed, thereby causing data loss!
|
// allowed, thereby causing data loss!
|
||||||
// Therefor, we want to be smarter still. We want to take into account which
|
// Therefore, we want to be smarter still. We want to take into account
|
||||||
// HTML tags are allowed and forbidden by the text format we're filtering
|
// which HTML tags are allowed and forbidden by the text format we're
|
||||||
// for, and if we're switching from another text format, we want to take
|
// filtering for, and if we're switching from another text format, we want
|
||||||
// that format's allowed and forbidden tags into account as well.
|
// to take that format's allowed and forbidden tags into account as well.
|
||||||
// In other words: we only expect markup allowed in both the original and
|
// In other words: we only expect markup allowed in both the original and
|
||||||
// the new format to continue to exist.
|
// the new format to continue to exist.
|
||||||
$format_restrictions = $format->getHtmlRestrictions();
|
$format_restrictions = $format->getHtmlRestrictions();
|
||||||
|
|
|
@ -74,7 +74,7 @@ class ContentEntityChangedTest extends EntityKernelTestBase {
|
||||||
|
|
||||||
// We can't assert equality here because the created time is set to the
|
// We can't assert equality here because the created time is set to the
|
||||||
// request time, while instances of ChangedTestItem use the current
|
// request time, while instances of ChangedTestItem use the current
|
||||||
// timestamp every time. Therefor we check if the changed timestamp is
|
// timestamp every time. Therefore we check if the changed timestamp is
|
||||||
// between the created time and now.
|
// between the created time and now.
|
||||||
$this->assertTrue(
|
$this->assertTrue(
|
||||||
($entity->getChangedTime() >= $entity->get('created')->value) &&
|
($entity->getChangedTime() >= $entity->get('created')->value) &&
|
||||||
|
|
|
@ -42,7 +42,7 @@ class ActiveLinkResponseFilterTest extends UnitTestCase {
|
||||||
'a',
|
'a',
|
||||||
// Unfortunately, it must also work on list items.
|
// Unfortunately, it must also work on list items.
|
||||||
'li',
|
'li',
|
||||||
// … and therefor, on *any* tag, really.
|
// … and therefore, on *any* tag, really.
|
||||||
'foo',
|
'foo',
|
||||||
];
|
];
|
||||||
$contents = [
|
$contents = [
|
||||||
|
|
Loading…
Reference in New Issue