File tree Expand file tree Collapse file tree 3 files changed +7
-5
lines changed 
library/Notifications/Model Expand file tree Collapse file tree 3 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 1818use  ipl \Html \Form ;
1919use  ipl \Html \HtmlString ;
2020use  ipl \Html \TemplateString ;
21+ use  ipl \Sql \Expression ;
2122use  ipl \Stdlib \Filter ;
2223use  ipl \Web \Compat \CompatController ;
2324use  ipl \Web \Compat \SearchControls ;
@@ -91,8 +92,8 @@ public function indexAction(): void
9192        );
9293
9394        $ emptyStateMessagenull ;
94-         if  (Contact::on (Database::get ())->columns ('1 ' )->limit (1 )->first () === null ) {
95-             if  (Channel::on (Database::get ())->columns ('1 ' )->limit (1 )->first () === null ) {
95+         if  (Contact::on (Database::get ())->columns ([ new   Expression ( '1 ' )] )->limit (1 )->first () === null ) {
96+             if  (Channel::on (Database::get ())->columns ([ new   Expression ( '1 ' )] )->limit (1 )->first () === null ) {
9697                $ addButtondisable ($ this translate ('A channel is required to add a contact group ' ));
9798
9899                $ emptyStateMessagecreate (
Original file line number Diff line number Diff line change 2020use  ipl \I18n \GettextTranslator ;
2121use  ipl \I18n \StaticTranslator ;
2222use  ipl \Sql \Connection ;
23+ use  ipl \Sql \Expression ;
2324use  ipl \Stdlib \Filter ;
2425use  ipl \Validator \EmailAddressValidator ;
2526use  ipl \Web \Common \CsrfCounterMeasure ;
@@ -128,13 +129,13 @@ protected function assemble(): void
128129
129130        if  ($ this channelId  !== null ) {
130131            $ isInUseon ($ this db )
131-                 ->columns ('1 ' )
132+                 ->columns ([ new   Expression ( '1 ' )] )
132133                ->filter (Filter::equal ('default_channel_id ' , $ this channelId ))
133134                ->first ();
134135
135136            if  ($ isInUsenull ) {
136137                $ isInUseon ($ this db )
137-                     ->columns ('1 ' )
138+                     ->columns ([ new   Expression ( '1 ' )] )
138139                    ->filter (Filter::equal ('channel_id ' , $ this channelId ))
139140                    ->first ();
140141            }
Original file line number Diff line number Diff line change @@ -145,7 +145,7 @@ public function delete(): void
145145        $ requirePriorityUpdatetrue ;
146146        if  (RotationConfigForm::EXPERIMENTAL_OVERRIDES ) {
147147            $ rotationsself ::on ($ db
148-                 ->columns ('1 ' )
148+                 ->columns ([ new   Expression ( '1 ' )] )
149149                ->filter (Filter::equal ('schedule_id ' , $ this schedule_id ))
150150                ->filter (Filter::equal ('priority ' , $ this priority ))
151151                ->first ();
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments