Skip to content

Whitespace indentation breaking in DocBlock #2877

@Ivorius

Description

@Ivorius
Subject Details
Rector version dev-master@85aa4dd
PHP version PHP 7.3
Full Command vendor/bin/rector process --set kdyby-translator-to-contributte-translation --dry-run
Demo link https://getrector.org/demo/f9279b5e-7528-4378-968a-89c18f5f3947#result

Current Behaviour

Change tab to space in DocBlock and property definition
image

Minimal PHP Code Causing Issue

<?php

use Doctrine\ORM\Mapping as ORM;


/**
 * @ORM\Entity()
 * @ORM\Table(name="slides")
 **/
class Slide
{
	/**
	 * @ORM\Column(type="boolean", nullable=FALSE, options={"default": 1})
	 * @var bool
	 */
	protected $active = true;
}

Expected Behaviour

Current tab should not be modified. Especially in this case when there is only set for refactoring class name.

Btw. why is FALSE transform to lowercase? Is there some configuration in rector for this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions