Code Duplication    Length = 1-3 lines in 4 locations

epubfs.php 1 location

@@ 56-58 (lines=3) @@
53
54
$idData = getURLParam('data', NULL);
55
$add = 'data=' . $idData . '&';
56
if (!is_null(GetUrlParam(DB))) {
57
    $add .= DB . '=' . GetUrlParam(DB) . '&';
58
}
59
$myBook = Book::getBookByDataId($idData);
60
61
$book = new EPub($myBook->getFilePath('EPUB', $idData));

epubreader.php 1 location

@@ 18-20 (lines=3) @@
15
16
$idData = getURLParam('data', NULL);
17
$add = 'data=' . $idData . '&';
18
if (!is_null (GetUrlParam (DB))) {
19
    $add .= DB . '=' . GetUrlParam (DB) . '&';
20
}
21
$myBook = Book::getBookByDataId($idData);
22
23
$book = new EPub($myBook->getFilePath('EPUB', $idData));

lib/Data.php 1 location

@@ 133-133 (lines=1) @@
130
        global $config;
131
132
        $database = "";
133
        if (!is_null (GetUrlParam (DB))) $database = GetUrlParam (DB) . "/";
134
135
        $href = "download/" . $this->id . "/" . $database;
136

lib/OPDS_renderer.php 1 location

@@ 97-97 (lines=1) @@
94
                if ($page->idPage)
95
                {
96
                    $idPage = $page->idPage;
97
                    if (!is_null (GetUrlParam (DB))) $idPage = str_replace ("cops:", "cops:" . GetUrlParam (DB) . ":", $idPage);
98
                    self::getXmlStream ()->text ($idPage);
99
                }
100
                else