Do not load DBIC::Optional::Dependencies at runtime unless we need to
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Storage / DBI / Pg.pm
index ded6d06..87a237d 100644 (file)
@@ -181,6 +181,8 @@ sub bind_attribute_by_data_type {
         );
       }
       elsif (
+        require DBIx::Class::Optional::Dependencies
+          and
         my $missing = DBIx::Class::Optional::Dependencies->req_missing_for([qw( rdbms_pg binary_data )])
       ) {
         # FIXME - perhaps this needs to be an exception too...?