From dcc8fef093e32a96d0534fa08d08f5a475be377e Mon Sep 17 00:00:00 2001 From: Edmar Moretti Date: Thu, 25 Aug 2016 22:02:24 -0300 Subject: [PATCH] Correção nas operações de salvar e recuperar mapa do banco --- classesphp/funcoes_gerais.php | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/classesphp/funcoes_gerais.php b/classesphp/funcoes_gerais.php index 8c19e7d..d1207c6 100755 --- a/classesphp/funcoes_gerais.php +++ b/classesphp/funcoes_gerais.php @@ -2944,14 +2944,13 @@ function restauraMapaAdmin($id_mapa,$dir_tmp){ $mapfile = str_ireplace("TYPE ANNOTATION","TYPE POINT",$mapfile); $mapfile = str_replace(array(""),"",$mapfile); $s = fwrite($baseh,$mapfile); - fclose($baseh); - } - - if (@ms_newMapObj($base)){ - return $base; - } - else{ - unlink($base); + fclose($baseh); + if (@ms_newMapObj($base)){ + return $base; + } + else{ + unlink($base); + } } return false; } -- libgit2 0.21.2