Permalink
Browse files

fix notices when not all positional parameters are passed. props cube…

…colour
  • Loading branch information...
1 parent a6aad28 commit a8669a7f51a0a2d9bdc9f5d6e39f24801d0d2510 @scribu committed Feb 15, 2013
Showing with 2 additions and 1 deletion.
  1. +2 −1 core.php
View
3 core.php
@@ -12,9 +12,10 @@
function wp_pagenavi( $args = array() ) {
if ( !is_array( $args ) ) {
$argv = func_get_args();
+
$args = array();
foreach ( array( 'before', 'after', 'options' ) as $i => $key )
- $args[ $key ] = $argv[ $i ];
+ $args[ $key ] = isset( $argv[ $i ]) ? $argv[ $i ] : "";
}
$args = wp_parse_args( $args, array(

0 comments on commit a8669a7

Please sign in to comment.