mirror of
https://github.com/opensourcepos/opensourcepos.git
synced 2026-05-30 19:26:22 -04:00
fix: address CodeRabbit review comments for encryption key persistence
- Always mirror encryption key to both .env and WRITEPATH (Docker safety) - Guard array key access with isset() before reading in Encryption.php - Fix encrypt_value() to not treat string '0' as empty - Improve error logging for failed encryption attempts
This commit is contained in:
@@ -493,7 +493,7 @@ class Config extends Secure_Controller
|
||||
if (!empty($passwordInput)) {
|
||||
$password = encrypt_value($passwordInput);
|
||||
if (empty($password)) {
|
||||
log_message('error', 'SMTP password encryption failed');
|
||||
log_message('error', 'SMTP password encryption failed - credentials not saved');
|
||||
|
||||
return $this->response->setJSON([
|
||||
'success' => false,
|
||||
|
||||
Reference in New Issue
Block a user