private function createBundleFile ($minifier, $fileName, $files, $sitePath, $bundleDir, $cleanCode = true)
    {
        $translator = $this->getServiceLocator()->get('translator');
        $message = '';
        $success = false;
        if (!empty($files)) {
            try {
                foreach ($files as $key => $file) {
                    //remove comments
                    if($cleanCode) {
                        $codeToAdd = $this->removeComments($sitePath . $file);
                    }else{
                        $codeToAdd = $sitePath . $file;
                    }
                    //add the file to minify later
                    $minifier->add($codeToAdd);
//                 $minifier = $this->getFileContentsViaCurl($minifier, $file);
                }
                //minify all the files
                $minifier->minify($bundleDir . $fileName);
                $message = $translator->translate('tr_front_minify_assets_compiled_successfully');
                $success = true;
            } catch (\Exception $ex) {
                /**
                 * this will occur only if the bundle.css or bundle.js
                 * is not writable or no permission or other errors
                 */
                  $message = wordwrap($ex->getMessage(), 20, "\n", true);
            }
        }else{
            $success = true;
        }

        return array(
            'message' => $message,
            'success' => $success
        );
    }