Skip to content
This repository was archived by the owner on Nov 27, 2024. It is now read-only.

Commit 08ae078

Browse files
authored
Merge pull request #3 from vend/update-uuid-regex
Add \^/$ asserting beginning and end of the string on UUID validator
2 parents 257efda + 9568c30 commit 08ae078

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

.travis.yml

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
11
language: php
22

33
php:
4-
- 5.5
5-
- 5.4
64
- 5.6
7-
- 7
8-
- hhvm
5+
- 7.2
96

107
install:
118
- composer install

src/Formats/PlainString.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88
class PlainString implements Format
99
{
10-
const FORMAT = '/[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}/i';
10+
const FORMAT = '/^[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}$/i';
1111

1212
/**
1313
* Whether the given value appears to fit this format

0 commit comments

Comments
 (0)