What are the advantages of using Sonarqube (Sonar) for code review in PHP projects?

Sonarqube (Sonar) is a powerful code review tool that can help identify code smells, bugs, and security vulnerabilities in PHP projects. By using Sonarqube, developers can ensure that their code meets quality standards, leading to better maintainability and reliability of the software.

// Example PHP code snippet
function calculateSum($a, $b) {
    return $a + $b;
}