mirror of
				https://github.com/firefly-iii/firefly-iii.git
				synced 2025-11-03 20:55:05 +00:00 
			
		
		
		
	Some small optimisations.
This commit is contained in:
		@@ -58,7 +58,8 @@ class HelpController extends Controller
 | 
			
		||||
            return Response::json($content);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        $content = $help->getFromGithub($language, $route);
 | 
			
		||||
        $content         = $help->getFromGithub($language, $route);
 | 
			
		||||
        $notYourLanguage = '<p><em>' . strval(trans('firefly.help_may_not_be_your_language')) . '</em></p>';
 | 
			
		||||
 | 
			
		||||
        // get backup language content (try English):
 | 
			
		||||
        if (strlen($content) === 0) {
 | 
			
		||||
@@ -68,12 +69,11 @@ class HelpController extends Controller
 | 
			
		||||
                $content = $help->getFromCache($route, $language);
 | 
			
		||||
            }
 | 
			
		||||
            if (!$help->inCache($route, $language)) {
 | 
			
		||||
                $content = $help->getFromGithub($language, $route);
 | 
			
		||||
                $content = '<p><em>' . strval(trans('firefly.help_may_not_be_your_language')) . '</em></p>' . $content;
 | 
			
		||||
                $content = trim($notYourLanguage . $help->getFromGithub($language, $route));
 | 
			
		||||
            }
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        if (strlen($content) === 0) {
 | 
			
		||||
        if ($content === $notYourLanguage) {
 | 
			
		||||
            $content = '<p>' . strval(trans('firefly.route_has_no_help')) . '</p>';
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -21,8 +21,6 @@ class AccountTypeSeeder extends Seeder
 | 
			
		||||
{
 | 
			
		||||
    public function run()
 | 
			
		||||
    {
 | 
			
		||||
        DB::table('account_types')->delete();
 | 
			
		||||
 | 
			
		||||
        AccountType::create(['type' => 'Default account']);
 | 
			
		||||
        AccountType::create(['type' => 'Cash account']);
 | 
			
		||||
        AccountType::create(['type' => 'Asset account']);
 | 
			
		||||
@@ -31,6 +29,7 @@ class AccountTypeSeeder extends Seeder
 | 
			
		||||
        AccountType::create(['type' => 'Initial balance account']);
 | 
			
		||||
        AccountType::create(['type' => 'Beneficiary account']);
 | 
			
		||||
        AccountType::create(['type' => 'Import account']);
 | 
			
		||||
        AccountType::create(['type' => 'Loan']);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -21,8 +21,6 @@ class TransactionCurrencySeeder extends Seeder
 | 
			
		||||
{
 | 
			
		||||
    public function run()
 | 
			
		||||
    {
 | 
			
		||||
        DB::table('transaction_currencies')->delete();
 | 
			
		||||
 | 
			
		||||
        TransactionCurrency::create(['code' => 'EUR', 'name' => 'Euro', 'symbol' => '€', 'decimal_places' => 2]);
 | 
			
		||||
        TransactionCurrency::create(['code' => 'USD', 'name' => 'US Dollar', 'symbol' => '$', 'decimal_places' => 2]);
 | 
			
		||||
        TransactionCurrency::create(['code' => 'HUF', 'name' => 'Hungarian forint', 'symbol' => 'Ft', 'decimal_places' => 2]);
 | 
			
		||||
 
 | 
			
		||||
@@ -21,9 +21,6 @@ class TransactionTypeSeeder extends Seeder
 | 
			
		||||
{
 | 
			
		||||
    public function run()
 | 
			
		||||
    {
 | 
			
		||||
 | 
			
		||||
        DB::table('transaction_types')->delete();
 | 
			
		||||
 | 
			
		||||
        TransactionType::create(['type' => TransactionType::WITHDRAWAL]);
 | 
			
		||||
        TransactionType::create(['type' => TransactionType::DEPOSIT]);
 | 
			
		||||
        TransactionType::create(['type' => TransactionType::TRANSFER]);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user