mirror of
https://github.com/ZoneMinder/zoneminder.git
synced 2025-12-23 22:37:53 -05:00
Fix for when there is no Model in Monitor
This commit is contained in:
@@ -588,7 +588,7 @@ sub model {
|
||||
|
||||
if (@_) {
|
||||
my $new = shift;
|
||||
if ($new ne $$self{Model}->Name()) {
|
||||
if ((!$$self{Model}) or ($new ne $$self{Model}->Name())) {
|
||||
$$self{Model} = ZoneMinder::Model->find_one(Name=>$new);
|
||||
if (!$$self{Model}) {
|
||||
$$self{Model} = new ZoneMinder::Model();
|
||||
|
||||
Reference in New Issue
Block a user