Skip to content

Commit

Permalink
add naming garble
Browse files Browse the repository at this point in the history
  • Loading branch information
eeliu committed Jun 19, 2024
1 parent 2c9a137 commit 56f348a
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions lib/Pinpoint/Common/AbstractClassFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,13 @@ public function markHasYield()

public function done()
{

$fullPath = Utils::$CLS_DIR . '/' . str_replace('\\', '/', $this->className) . '.php';
// only for support phpunit test
if (defined('PHPUNIT_COMPOSER_INSTALL')) {
$fullPath = Utils::$CLS_DIR . '/' . str_replace('\\', '/', $this->className) . '.php';
} else {
$file_uuid_name = uniqid("pinpoint_");
$fullPath = Utils::$CLS_DIR . '/' . $file_uuid_name . '.php';
}
$context = $this->_astPrinter->prettyPrintFile($this->newAstNode);
MonitorClass::getInstance()->insertMapping($this->className, $fullPath);
Logger::Inst()->debug("map/save new class '$this->className' to '$fullPath' ");
Expand Down

0 comments on commit 56f348a

Please sign in to comment.