Skip to content

Commit 5e00647

Browse files
committed
direct reference to class within mapTypeToClass
- for HeadingOne, HeadingTwo and HeadingThree
1 parent f9e1947 commit 5e00647

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Entities/Blocks/Block.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -192,11 +192,11 @@ private static function mapTypeToClass(string $type): string
192192
$class = str_replace('_', '', ucwords($type, '_'));
193193
return "FiveamCode\\LaravelNotionApi\\Entities\\Blocks\\" . $class;
194194
case 'heading_1':
195-
return "FiveamCode\\LaravelNotionApi\\Entities\\Blocks\\HeadingOne";
195+
return HeadingOne::class;
196196
case 'heading_2':
197-
return "FiveamCode\\LaravelNotionApi\\Entities\\Blocks\\HeadingTwo";
197+
return HeadingTwo::class;
198198
case 'heading_3':
199-
return "FiveamCode\\LaravelNotionApi\\Entities\\Blocks\\HeadingThree";
199+
return HeadingThree::class;
200200
default:
201201
return Block::class;
202202
}

0 commit comments

Comments
 (0)