Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
206 changes: 103 additions & 103 deletions composer.lock

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion src/Console/AIAgentChatConsoleCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
use NeuronAI\Chat\Messages\UserMessage;
use Symfony\Component\Console\Attribute\AsCommand;
use Symfony\Component\Console\Command\Command;
use Symfony\Component\Console\Helper\QuestionHelper;
use Symfony\Component\Console\Input\InputInterface;
use Symfony\Component\Console\Output\OutputInterface;
use Symfony\Component\Console\Question\Question;
Expand All @@ -37,8 +38,8 @@ protected function execute(InputInterface $input, OutputInterface $output): int
return Command::SUCCESS;
}

/** @var \Symfony\Component\Console\Helper\QuestionHelper $helper */
$helper = $this->getHelper('question');
assert($helper instanceof QuestionHelper);

$io->block(
messages: [
Expand Down
2 changes: 1 addition & 1 deletion src/Controller/AIChatRequestHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,8 @@ public function clearChat(): Response
public function chatSse(Request $request): EventStreamResponse
{
return new EventStreamResponse(function (EventStreamResponse $response) use ($request): void {
/** @var string $message */
$message = $request->query->get('message');
assert(is_string($message));

$response->sendEvent(new ServerSentEvent(
data: $this->twig->render('html/chat/message.html.twig', [
Expand Down
2 changes: 1 addition & 1 deletion src/Domain/Athlete/Weight/AthleteWeightHistoryChart.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ public function build(): array
$athleteWeights,
);

/** @var AthleteWeight $firstAthleteWeight */
$firstAthleteWeight = reset($athleteWeights);
assert($firstAthleteWeight instanceof AthleteWeight);

$zoomEndValue = $this->now->format('Y-m-d');
$zoomStartValue = $firstAthleteWeight->getOn()->format('Y-m-d');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,12 @@ public static function create(
*/
public function build(): array
{
/** @var SegmentEffort[] $effortsWithHeartRate */
$effortsWithHeartRate = array_values(array_filter(
$this->segmentEfforts->toArray(),
fn (SegmentEffort $effort): bool => null !== $effort->getAverageHeartRate(),
));

if (empty($effortsWithHeartRate)) {
if ([] === $effortsWithHeartRate) {
return [];
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ public function process(ContainerBuilder $container): void
[$prefix, $lockName] = explode('.', (string) $mutexDefinitionId);

foreach ($constructorParams as $param) {
/** @var \ReflectionNamedType $type */
$type = $param->getType();
assert($type instanceof \ReflectionNamedType);
$definitionArguments[] = match ($param->getName()) {
'lockName' => LockName::from($lockName),
default => new Reference($type->getName()),
Expand Down
4 changes: 2 additions & 2 deletions src/Infrastructure/Twig/SvgsTwigExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,25 +24,25 @@ public function svg(string $name, ?string $size = null, ?string $iconColor = nul
$svg = $this->load('icons', $name);

if ($size) {
/** @var non-empty-string $svg */
$svg = preg_replace_callback('/class="([^"]+)"/', function (array $matches) use ($size): string {
$classes = explode(' ', $matches[1]);
$classes = array_filter($classes, fn (string $class): bool => !preg_match('/^(w-|h-|size-)/', $class));
$classes[] = $size;

return 'class="'.implode(' ', $classes).'"';
}, $svg);
assert(is_string($svg) && '' !== $svg);
}

if (null !== $iconColor) {
/** @var non-empty-string $svg */
$svg = preg_replace_callback('/class="([^"]+)"/', function (array $matches) use ($iconColor): string {
$classes = explode(' ', $matches[1]);
$classes = array_filter($classes, fn (string $class): bool => !preg_match('/^(text-|hover:text|fill-|stroke-)/', $class));
$classes[] = $iconColor;

return 'class="'.trim(implode(' ', $classes)).'"';
}, $svg);
assert(is_string($svg) && '' !== $svg);
}

return $svg;
Expand Down
6 changes: 3 additions & 3 deletions src/Kernel.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@ public function build(ContainerBuilder $container): void
protected function initializeContainer(): void
{
parent::initializeContainer();
/** @var KeyValueStore $keyValueStore */
$keyValueStore = $this->getContainer()->get(KeyValueStore::class);
assert($keyValueStore instanceof KeyValueStore);
Theme::setKeyValueStore($keyValueStore);

/** @var KernelProjectDir $kernelProjectDir */
$kernelProjectDir = $this->getContainer()->get(KernelProjectDir::class);
/** @var PlatformEnvironment $platformEnvironment */
assert($kernelProjectDir instanceof KernelProjectDir);
$platformEnvironment = $this->getContainer()->get(PlatformEnvironment::class);
assert($platformEnvironment instanceof PlatformEnvironment);
AppConfig::init(
kernelProjectDir: $kernelProjectDir,
platformEnvironment: $platformEnvironment
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Startedon0811202514:47:03



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ StatisticsforStravav4.7.0



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ StatisticsforStravav4.7.0



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ StatisticsforStravav4.7.0



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ StatisticsforStravav4.7.0



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ StatisticsforStravav4.7.0



Runtime:PHP8.5.x(cli)Symfony8.0.6Linux
Runtime:PHP8.5.x(cli)Symfony8.0.7Linux

Configurationfiles:
config.yaml
Expand Down