Skip to content

Commit

Permalink
Merge pull request #3165 from microsoft/fix/php-generation
Browse files Browse the repository at this point in the history
Fix issue naming classes and uses when there is alias.
  • Loading branch information
SilasKenneth authored Aug 17, 2023
2 parents a02d736 + 1ed1c6d commit b829505
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed

- Fix issue with generating classes with Aliases(PHP)[microsoftgraph/msgraph-beta-sdk-php#197](https://github.com/microsoftgraph/msgraph-beta-sdk-php/pull/197)
- Flattens the models namespaces in Ruby to avoid circular dependencies.
- Adds ObjectId as a reserved keyword in Ruby to have memory management issues.
- Replace Javax annotations in favor of Jakarta annotations for Java code generation. [#2810](https://github.com/microsoft/kiota/issues/2810)
Expand Down
1 change: 0 additions & 1 deletion src/Kiota.Builder/Refiners/PhpRefiner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,6 @@ private static void AliasUsingWithSameSymbol(CodeElement currentElement)
.Select(x => x.ToFirstCharacterUpperCase())
.ToArray());
usingElement.Alias = $"{(string.IsNullOrEmpty(replacement) ? string.Empty : $"\\{replacement}")}\\{usingElement.Declaration!.TypeDefinition!.Name.ToFirstCharacterUpperCase()}";
usingElement.Declaration.Name = usingElement.Alias;
}
}
CrawlTree(currentElement, AliasUsingWithSameSymbol);
Expand Down

0 comments on commit b829505

Please sign in to comment.