Added online check

This commit is contained in:
Shoghi Cervantes Pueyo 2013-01-22 18:21:41 +01:00
parent b589b69beb
commit bf5df18170
2 changed files with 24 additions and 1 deletions

View file

@ -26,6 +26,9 @@ the Free Software Foundation, either version 3 of the License, or
*/
function UPnP_PortForward($port){
if(Utils::$online === false){
return false;
}
if(Utils::getOS() != "win" or !class_exists("COM")){
return false;
}
@ -44,6 +47,9 @@ function UPnP_PortForward($port){
}
function UPnP_RemovePortForward($port){
if(Utils::$online === false){
return false;
}
if(Utils::getOS() != "win" or !class_exists("COM")){
return false;
}