Support 'use Web::Simple;' to default to current package
Matt S Trout [Sun, 24 Oct 2010 14:20:25 +0000 (15:20 +0100)]
Changes
lib/Web/Simple.pm

diff --git a/Changes b/Changes
index e5242ca..7f33bd6 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,5 +1,7 @@
 Change log for Web::Simple
 
+  - Support 'use Web::Simple;' to default to current package
+
 0.004 - Thu Jul 08 2010 22:08 UTC
   - Hide Plack Modules from PAUSE
 
index 797d96f..9d5efbb 100644 (file)
@@ -23,7 +23,7 @@ sub setup_dispatch_strictures {
 sub import {
   setup_dispatch_strictures();
   my ($class, $app_package) = @_;
-  $class->_export_into($app_package);
+  $class->_export_into($app_package||caller);
 }
 
 sub _export_into {