AshishJoshi-asj / zfdatagrid

Automatically exported from code.google.com/p/zfdatagrid
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

function Bvb_Grid_DataGrid::getInfo() #99

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
1. why not to add optional 2 parameter to receive default value
2. what if param is boolean ? i think as default it should return NULL and 
not FALSE

    /**
     * Return variable stored in info. Return default if value is not 
stored.  
     *
     * @param string $param
     * @param mixed  $default
     * 
     * @return mixed
     */    
    public function getInfo($param, $default = false) {
        if (isset($this->info[$param])) {
            return $this->info[$param];
        } else {
            return $default;
        }
    }    

Original issue reported on code.google.com by martin.m...@gmail.com on 7 Jan 2010 at 1:20

GoogleCodeExporter commented 9 years ago
Hi Martin,

Done.

Best Regards,
Bento Vilas Boas

Original comment by pao.fre...@gmail.com on 9 Jan 2010 at 5:15

GoogleCodeExporter commented 9 years ago
could you pls. change also the doc part ?

Original comment by martin.m...@gmail.com on 10 Jan 2010 at 12:42

GoogleCodeExporter commented 9 years ago
Done.

Best Regards,
Bento Vilas Boas

Original comment by pao.fre...@gmail.com on 10 Jan 2010 at 4:09

GoogleCodeExporter commented 9 years ago

Original comment by martin.m...@gmail.com on 11 Jan 2010 at 8:51