Skip to content

Instantly share code, notes, and snippets.

View liyo's full-sized avatar
🏠
Working from home

Pablo Wolochwianski liyo

🏠
Working from home
View GitHub Profile
@Ocramius
Ocramius / User.php
Last active September 23, 2025 16:13
Doctrine 2 ManyToMany - the correct way
<?php
use Doctrine\ORM\Mapping as ORM;
use Doctrine\Common\Collections\ArrayCollection;
/**
* @ORM\Entity()
* @ORM\Table(name="user")
*/
class User