Showing 1,726 of 2,403 total issues
Method handleQuery
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function handleQuery(ServerRequestInterface $request, Builder $query, array $search_columns, array $sort_columns, Closure $callback): ResponseInterface
{
$search = Validator::queryParams($request)->array('search')['value'] ?? '';
$start = Validator::queryParams($request)->integer('start', 0);
$length = Validator::queryParams($request)->integer('length', 0);
Method handle
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function handle(ServerRequestInterface $request): ResponseInterface
{
$this->layout = 'layouts/administration';
$parent_id = $request->getAttribute('parent_id');
Method topTenGrandFamilyQuery
has 38 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function topTenGrandFamilyQuery(int $total): array
{
return DB::table('families')
->join('link AS children', static function (JoinClause $join): void {
$join
Method createTextBox
has 12 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
float $width,
float $height,
bool $border,
string $bgcolor,
bool $newline,
Method createTextBox
has 12 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
float $width,
float $height,
bool $border,
string $bgcolor,
bool $newline,
Method createTextBox
has 12 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
float $width,
float $height,
bool $border,
string $bgcolor,
bool $newline,
Method __construct
has 12 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
float $width,
float $height,
bool $border,
string $bgcolor,
bool $newline,
Method target
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function target()
{
if (!preg_match('/^@(' . Gedcom::REGEX_XREF . ')@$/', $this->value(), $match)) {
return null;
}
Method individualBoxFacts
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function individualBoxFacts(Individual $individual): string
{
$html = '';
$opt_tags = preg_split('/\W/', $individual->tree()->getPreference('CHART_BOX_TAGS'), 0, PREG_SPLIT_NO_EMPTY);
Method getBlock
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function getBlock(Tree $tree, int $block_id, string $context, array $config = []): string
{
$gedcomid = $tree->getUserPreference(Auth::user(), UserInterface::PREF_TREE_ACCOUNT_XREF);
$individual = Registry::individualFactory()->make($gedcomid, $tree);
$links = [];
Method loadIndividuals
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
private function loadIndividuals(Tree $tree, string $surname, bool $soundex_dm, bool $soundex_std): array
{
$individuals = DB::table('individuals')
->join('name', static function (JoinClause $join): void {
$join
Method getBlock
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function getBlock(Tree $tree, int $block_id, string $context, array $config = []): string
{
$messages = DB::table('message')
->where('user_id', '=', Auth::id())
->orderByDesc('message_id')
Method create
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function create(string $name, string $title): Tree
{
DB::table('gedcom')->insert([
'gedcom_name' => $name,
]);
Method getEventsList
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function getEventsList(int $jd1, int $jd2, string $events, bool $only_living, string $sort_by, Tree $tree): Collection
{
$found_facts = [];
$facts = new Collection();
Method handle
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function handle(ServerRequestInterface $request): ResponseInterface
{
$tree = Validator::attributes($request)->tree();
$xref = Validator::attributes($request)->isXref()->string('xref');
$fact_id = Validator::attributes($request)->string('fact_id');
Method updateUserBlocks
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function updateUserBlocks(int $user_id, Collection $main_block_ids, Collection $side_block_ids): void
{
$existing_block_ids = DB::table('block')
->where('user_id', '=', $user_id)
->whereIn('location', [ModuleBlockInterface::MAIN_BLOCKS, ModuleBlockInterface::SIDE_BLOCKS])
Method updateTreeBlocks
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function updateTreeBlocks(int $tree_id, Collection $main_block_ids, Collection $side_block_ids): void
{
$existing_block_ids = DB::table('block')
->where('gedcom_id', '=', $tree_id)
->whereIn('location', [ModuleBlockInterface::MAIN_BLOCKS, ModuleBlockInterface::SIDE_BLOCKS])
Method chartChildren
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function chartChildren(): string
{
$data = [
[
I18N::translate('Century'),
Method columns
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
public function columns(): array
{
return [
new CensusColumnFullName($this, 'Name', 'Name of each person in family, household or institution'),
new CensusColumnNull($this, 'Address', 'Place of Habitation'),
Method factsStartHandler
has 37 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
protected function factsStartHandler(array $attrs): void
{
$this->process_repeats++;
if ($this->process_repeats > 1) {
return;