set default in display, not build to avoid errors

This commit is contained in:
Daku 2015-04-06 17:25:46 +01:00 committed by Shish
parent be18140944
commit 598df41b1d
5 changed files with 7 additions and 7 deletions

View file

@ -84,7 +84,7 @@ class BaseThemelet {
* @param int $page_number
* @param int $total_pages
*/
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random) {
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random = FALSE) {
if($total_pages == 0) $total_pages = 1;
$body = $this->build_paginator($page_number, $total_pages, $base, $query, $show_random);
$page->add_block(new Block(null, $body, "main", 90, "paginator"));
@ -129,7 +129,7 @@ class BaseThemelet {
* @param string $query
* @return string
*/
private function build_paginator($current_page, $total_pages, $base_url, $query, $show_random = FALSE) {
private function build_paginator($current_page, $total_pages, $base_url, $query, $show_random) {
$next = $current_page + 1;
$prev = $current_page - 1;

View file

@ -7,7 +7,7 @@ class Themelet extends BaseThemelet {
* @param int $page_number
* @param int $total_pages
*/
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random) {
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random = FALSE) {
if($total_pages == 0) $total_pages = 1;
$body = $this->build_paginator($page_number, $total_pages, $base, $query);
$page->add_block(new Block(null, $body, "main", 90));

View file

@ -7,7 +7,7 @@ class Themelet extends BaseThemelet {
* @param int $page_number
* @param int $total_pages
*/
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random) {
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random = FALSE) {
if($total_pages == 0) $total_pages = 1;
$body = $this->build_paginator($page_number, $total_pages, $base, $query);
$page->add_block(new Block(null, $body, "main", 90));

View file

@ -11,7 +11,7 @@ class Themelet extends BaseThemelet {
* @param int $total_pages
* @param int $position
*/
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random) {
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random = FALSE) {
if($total_pages == 0) $total_pages = 1;
$body = $this->futaba_build_paginator($page_number, $total_pages, $base, $query);
$page->add_block(new Block(null, $body, "main", 90));

View file

@ -28,7 +28,7 @@ class Themelet extends BaseThemelet {
* @param int $page_number
* @param int $total_pages
*/
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random) {
public function display_paginator(Page $page, $base, $query, $page_number, $total_pages, $show_random = FALSE) {
if($total_pages == 0) $total_pages = 1;
$body = $this->litetheme_build_paginator($page_number, $total_pages, $base, $query, $show_random);
$page->add_block(new Block(null, $body, "main", 90));
@ -71,7 +71,7 @@ class Themelet extends BaseThemelet {
* @param string $query
* @return string
*/
public function litetheme_build_paginator($current_page, $total_pages, $base_url, $query) {
public function litetheme_build_paginator($current_page, $total_pages, $base_url, $query, $show_random) {
$next = $current_page + 1;
$prev = $current_page - 1;