[ticket/297] Rename version_check method to check to prevent 2nd constructor
B3P-297
This commit is contained in:
@@ -148,7 +148,7 @@ class portal_module
|
||||
else
|
||||
{
|
||||
// only show the mod version check if we are on the General Settings page
|
||||
$this->version_check->version_check();
|
||||
$this->version_check->check();
|
||||
}
|
||||
|
||||
$this->new_config = $this->config;
|
||||
|
||||
@@ -67,7 +67,7 @@ class version_check
|
||||
* @param bool $return_version Yes if current version should be returned
|
||||
* @return string Current version if $return_version is set to true
|
||||
*/
|
||||
public function version_check($return_version = false)
|
||||
public function check($return_version = false)
|
||||
{
|
||||
if (!function_exists('get_remote_file'))
|
||||
{
|
||||
|
||||
@@ -39,8 +39,8 @@ class phpbb_functions_version_check_test extends \board3\portal\tests\testframew
|
||||
public function test_version_check()
|
||||
{
|
||||
$this->assertTrue(true);
|
||||
$this->assertNull($this->version_check->version_check());
|
||||
$this->assertEquals('2.1.0', $this->version_check->version_check(true));
|
||||
$this->assertNull($this->version_check->check());
|
||||
$this->assertEquals('2.1.0', $this->version_check->check(true));
|
||||
$this->template->assert_equals(array(
|
||||
'CURRENT_VERSION' => '2.1.0',
|
||||
'TITLE' => 'Board3 Portal',
|
||||
|
||||
Reference in New Issue
Block a user