Skip to content

Commit

Permalink
no message
Browse files Browse the repository at this point in the history
  • Loading branch information
lanhktc committed Oct 18, 2019
1 parent d3131ed commit d2af85b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions app/Http/Controllers/GeneralController.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace App\Http\Controllers;

use App\Http\Controllers\Controller;
use App\Models\Subscribe;
use App\Models\ShopSubscribe;
use Illuminate\Http\Request;
use Mail;
use View;
Expand Down Expand Up @@ -40,11 +40,11 @@ public function __construct()
}

/**
* [emailSubscribe description]
* [emailShop description]
* @param Request $request [description]
* @return [type] [description]
*/
public function emailSubscribe(Request $request)
public function emailShop(Request $request)
{
$data = $request->all();
$validator = $request->validate([
Expand All @@ -54,9 +54,9 @@ public function emailSubscribe(Request $request)
'subscribe_email.email' => trans('validation.email'),
]);

$checkEmail = Subscribe::where('email', $data['subscribe_email'])->first();
$checkEmail = ShopSubscribe::where('email', $data['subscribe_email'])->first();
if (!$checkEmail) {
Subscribe::insert(['email' => $data['subscribe_email']]);
ShopSubscribe::insert(['email' => $data['subscribe_email']]);
}
return redirect()->back()->with(['message' => trans('front.subscribe.subscribe_success')]);
}
Expand Down
2 changes: 1 addition & 1 deletion config/scart.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
return [
'version' => '3.0.4.2',
'version' => '3.0.4.3',
'homepage' => 'https://s-cart.org',
'name' => 'S-Cart',
'title' => 'Free Open Source eCommerce for Business',
Expand Down

0 comments on commit d2af85b

Please sign in to comment.