api_get_page_type does not return value on second call

Migrated issue

Reported by: anoopjohn

The function api_get_page_type uses a static variable and a static flag to prevent execution of the logic the second time but the return statement is inside the condition where the static flag is checked. So subsequent calls to the function does not return any value. Only the first call returns the page type correctly.

Assignee Loading
Time tracking Loading