projects
/
p5sagit/Config-Any.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
added is_supported() to see what plugins we can use
[p5sagit/Config-Any.git]
/
lib
/
Config
/
Any
/
INI.pm
diff --git
a/lib/Config/Any/INI.pm
b/lib/Config/Any/INI.pm
index
1d0575e
..
d281e60
100644
(file)
--- a/
lib/Config/Any/INI.pm
+++ b/
lib/Config/Any/INI.pm
@@
-65,6
+65,17
@@
sub load {
return $out;
}
+=head2 is_supported( )
+
+Returns true if L<Config::Tiny> is available.
+
+=cut
+
+sub is_supported {
+ eval { require Config::Tiny; };
+ return $@ ? 0 : 1;
+}
+
=head1 PACKAGE VARIABLES
=over 4