From: Rafael Kitover Date: Sat, 31 Oct 2009 20:22:37 +0000 (+0000) Subject: fix regex to numify sqlite_version X-Git-Tag: v0.08113~21 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f05ba46f586061053518a4cdcc59a7b7fd602a29;p=dbsrgits%2FDBIx-Class.git fix regex to numify sqlite_version --- diff --git a/lib/DBIx/Class/Storage/DBI/SQLite.pm b/lib/DBIx/Class/Storage/DBI/SQLite.pm index 48d55fe..c119f4e 100644 --- a/lib/DBIx/Class/Storage/DBI/SQLite.pm +++ b/lib/DBIx/Class/Storage/DBI/SQLite.pm @@ -56,7 +56,7 @@ sub deployment_statements { my $sqlite_version = $self->_get_dbh->{sqlite_version}; # numify, SQLT does a numeric comparison - $sqlite_version =~ s/^(\d+) \. (\d+) (?: \. (\d+)) .*/${1}.${2}/x; + $sqlite_version =~ s/^(\d+) \. (\d+) (?: \. (\d+))? .*/${1}.${2}/x; $sqltargs->{producer_args}{sqlite_version} = $sqlite_version;