1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Fixed Unnecessary Code in XenForo_Helper_File

Discussion in 'Resolved Bug Reports' started by ragtek, Dec 21, 2010.

  1. ragtek

    ragtek Guest

    Class: XenForo_Helper_File
    Method: public static function getTempDir()

    There's a unnecessary code in the method
            return self::getInternalDataPath() . '/temp';

    $tempDir = @ini_get('upload_tmp_dir');
            if (

    You have a return at the beginn of the method, which means that the code after it, never will run, so you can delete it;)

    It's minimalistic but it would be nicer to have a clean & nice code;)
    Vincent likes this.
  2. Mike

    Mike XenForo Developer Staff Member

    I wasn't sure if the new code was going to stick, but it doesn't seem to have any issues, so no need for the old code.
    Vincent likes this.

Share This Page