mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 07:49:52 +03:00
Check size for sneding customizations
This commit is contained in:
@@ -263,9 +263,9 @@ const SettingsCustomization: FC = () => {
|
||||
(new_de.ma ? '<' + new_de.ma : '')
|
||||
);
|
||||
|
||||
// check size in bytes to match buffer in CPP, which is 4096
|
||||
// check size in bytes to match buffer in CPP, which is 2048
|
||||
const bytes = new TextEncoder().encode(JSON.stringify(masked_entities)).length;
|
||||
if (bytes > 4000) {
|
||||
if (bytes > 2000) {
|
||||
enqueueSnackbar(LL.CUSTOMIZATIONS_FULL(), { variant: 'warning' });
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user