Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Array
- (
- [test] => Array
- (
- [0] => Array
- (
- [a] => Array
- (
- [0] => 1
- )
- [b] => Array
- (
- [0] => 2
- )
- [c] => Array
- (
- [0] => 3
- )
- Array
- (
- [test] => Array
- (
- [0] => Array
- (
- [a] => 1
- [b] => 2
- [c] => 3
- function optimize( $config )
- {
- foreach ( $config as $key => $value )
- if( is_array( $value ) && count( $value ) == 1 && isset( $value[0] ))
- $config[$key] = $value[0];
- return $config
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement