Important update for email

###Very important update for emails
Handling cipher update scenario for decrypt email password
Not loading email passoword on edit page to secure email account
This commit is contained in:
Manish Verma
2018-08-16 20:32:16 +05:30
parent fdfc8f383c
commit 6941280996
2 changed files with 7 additions and 3 deletions

View File

@@ -60,8 +60,12 @@ class Emails extends BaseModel
public function getPasswordAttribute($value)
{
if ($value) {
return \Crypt::decrypt($value);
try{
if ($value) {
return \Crypt::decrypt($value);
}
} catch(\Exception $e) {
return null;
}
return $value;

View File

@@ -67,7 +67,7 @@ class="active"
<div class="col-xs-6 form-group {!! $errors->has('password') ? 'has-error' : ''!!}" id="password_error">
{!! Form::label('password',Lang::get('lang.password')) !!} <span class="text-red"> *</span>
{!! $errors->first('password', '<spam class="help-block">:message</spam>') !!}
<input type="password" name="password" class="form-control" id="password" value={!! $emails->password !!} >
<input type="password" name="password" class="form-control" id="password">
</div>
</div>
</div>