Skip to content

Commit 99d0d91

Browse files
committed
SDK-766: Remove unneeded method
1 parent be1c047 commit 99d0d91

File tree

1 file changed

+3
-14
lines changed

1 file changed

+3
-14
lines changed

src/Yoti/Util/Profile/AttributeConverter.php

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ private static function convertValueBasedOnAttributeName($value, $attrName)
5656
*/
5757
private static function convertValueBasedOnContentType($value, $contentType)
5858
{
59-
self::validateInput($value, $contentType);
59+
if (empty($value) && ($contentType !== self::CONTENT_TYPE_STRING)) {
60+
throw new AttributeException("Warning: Value is NULL");
61+
}
6062

6163
switch ($contentType) {
6264
case self::CONTENT_TYPE_JPEG:
@@ -196,17 +198,4 @@ public static function convertTimestampToDate($value)
196198
{
197199
return (new \DateTime())->setTimestamp(strtotime($value));
198200
}
199-
200-
/**
201-
* @param string $value
202-
* @param int $value
203-
*
204-
* @throws AttributeException
205-
*/
206-
private static function validateInput($value, $contentType)
207-
{
208-
if (empty($value) && ($contentType !== self::CONTENT_TYPE_STRING)) {
209-
throw new AttributeException("Warning: Value is NULL");
210-
}
211-
}
212201
}

0 commit comments

Comments
 (0)