- &Header::openbox('100%', 'center', "Swap $Lang::tr{'graph'}");
- &Graphs::makegraphbox("memory.cgi","swap","day");
- &Header::closebox();
+ if ( `ls $mainsettings{'RRDLOG'}/collectd/localhost/swap 2>/dev/null` ) {
+ &Header::openbox('100%', 'center', "Swap $Lang::tr{'graph'}");
+ &Graphs::makegraphbox("memory.cgi","swap","day");
+ &Header::closebox();
+ }