Improve moniker_map coderef documentation (GH#7)
Dagfinn Ilmari Mannsåker [Mon, 10 Apr 2017 13:54:41 +0000 (14:54 +0100)]
Rather than using the suggested patch, use a proper list for the
coderef arguments.

Changes
lib/DBIx/Class/Schema/Loader/Base.pm

diff --git a/Changes b/Changes
index e90cfaa..2546338 100644 (file)
--- a/Changes
+++ b/Changes
@@ -2,6 +2,7 @@ Revision history for Perl extension DBIx::Class::Schema::Loader
 
         - Avoid upcoming DBIC warning on implicit SELECT * invocation
           (RT#118178)
+        - Improve moniker_map coderef documentation (GH#7)
 
 0.07046  2016-09-05
         - Introspect view definitions for PostgreSQL, MySQL, Oracle,
index ba7d8b3..a0b252d 100644 (file)
@@ -613,14 +613,27 @@ a hashref of unqualified table name keys and moniker values
 
 =item *
 
-a coderef for a translator function taking a L<table
-object|DBIx::Class::Schema::Loader::Table> argument (which stringifies to the
-unqualified table name) and returning a scalar moniker
-
-The function is also passed a coderef that can be called with either
-of the hashref forms to get the moniker mapped accordingly.  This is
-useful if you need to handle some monikers specially, but want to use
-the hashref form for the rest.
+a coderef that returns the moniker, which is called with the following
+arguments:
+
+=over
+
+=item *
+
+the L<DBIx::Class::Schema::Loader::Table> object for the table
+
+=item *
+
+the default moniker that DBIC would ordinarily give this table
+
+=item *
+
+a coderef that can be called with either of the hashref forms to get
+the moniker mapped accordingly.  This is useful if you need to handle
+some monikers specially, but want to use the hashref form for the
+rest.
+
+=back
 
 =back