File tree Expand file tree Collapse file tree 3 files changed +28
-8
lines changed Expand file tree Collapse file tree 3 files changed +28
-8
lines changed Original file line number Diff line number Diff line change @@ -765,21 +765,29 @@ public class Services.CalDAV : GLib.Object {
765765 }
766766
767767 public bool is_vtodo (GXml . DomElement element) {
768- bool return_value = false ;
768+ GXml . DomHTMLCollection propstat = element . get_elements_by_tag_name ( " d:propstat " ) ;
769769
770- GXml . DomElement propstat = element. get_elements_by_tag_name (" d:propstat" ). get_element (0 );
771- GXml . DomElement prop = propstat. get_elements_by_tag_name (" d:prop" ). get_element (0 );
772- GXml . DomHTMLCollection getcontenttype = prop. get_elements_by_tag_name (" d:getcontenttype" );
770+ if (propstat. length <= 0 ) {
771+ return false ;
772+ }
773+
774+ GXml . DomHTMLCollection prop = propstat. get_element (0 ). get_elements_by_tag_name (" d:prop" );
775+
776+ if (prop. length <= 0 ) {
777+ return false ;
778+ }
779+
780+ GXml . DomHTMLCollection getcontenttype = prop. get_element (0 ). get_elements_by_tag_name (" d:getcontenttype" );
773781
774782 if (getcontenttype. length <= 0 ) {
775- return return_value ;
783+ return false ;
776784 }
777785
778786 if (getcontenttype. get_element (0 ). text_content. index_of (" vtodo" ) > - 1 ) {
779- return_value = true ;
787+ return true ;
780788 }
781789
782- return return_value ;
790+ return false ;
783791 }
784792
785793 /*
Original file line number Diff line number Diff line change 6767 <url type =" donation" >https://www.patreon.com/alainm23</url >
6868 <
launchable type =
" desktop-id" >@
[email protected] </
launchable >
6969 <releases >
70+ <release version =" 4.5.12" date =" 2024-03-29" >
71+ <description translatable =" no" >
72+ <ul >
73+ <li >Fixed bug when syncing on Nextcloud.</li >
74+ <li >Dutch translation update thanks to @Gert-dev.</li >
75+ <li >Spanish translation update thanks to @haggen88.</li >
76+ <li >German translation update thanks to @bestlinuxgamers.</li >
77+ <li >Hindi translation update thanks to @Scrambled777.</li >
78+ </ul >
79+ </description >
80+ </release >
81+
7082 <release version =" 4.5.11" date =" 2024-03-28" >
7183 <description translatable =" no" >
7284 <ul >
Original file line number Diff line number Diff line change 11project (
22 ' io.github.alainm23.planify' ,
33 ' vala' , ' c' ,
4- version : ' 4.5.11 '
4+ version : ' 4.5.12 '
55)
66
77gnome = import (' gnome' )
You can’t perform that action at this time.
0 commit comments