diff --git a/core/modules/image/src/Entity/ImageStyle.php b/core/modules/image/src/Entity/ImageStyle.php
index 32e5d3b..a57904d 100644
--- a/core/modules/image/src/Entity/ImageStyle.php
+++ b/core/modules/image/src/Entity/ImageStyle.php
@@ -66,14 +66,14 @@ class ImageStyle extends ConfigEntityBase implements ImageStyleInterface, Entity
    *
    * @var string
    */
-  public $name;
+  protected $name;
 
   /**
    * The image style label.
    *
    * @var string
    */
-  public $label;
+  protected $label;
 
   /**
    * The array of image effects for this image style.
diff --git a/core/modules/image/src/Tests/ImageAdminStylesTest.php b/core/modules/image/src/Tests/ImageAdminStylesTest.php
index 3ecf7c7..65f354e 100644
--- a/core/modules/image/src/Tests/ImageAdminStylesTest.php
+++ b/core/modules/image/src/Tests/ImageAdminStylesTest.php
@@ -246,7 +246,7 @@ function testStyle() {
       'Effect with ID %uuid no longer found on image style %style',
       array(
         '%uuid' => $uuids['image_crop'],
-        '%style' => $style->label,
+        '%style' => $style->label(),
       )));
 
     // Additional test on Rotate effect, for transparent background.