Skip to content

Commit 745f5ca

Browse files
Use safe keyword when hook target namspace clashes with reserved java keywords (#426)
1 parent 1c22582 commit 745f5ca

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

python/rpdk/java/codegen.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@ def generate_hook(self, src, project): # pylint: disable=too-many-statements
635635
target_schema = target_info["Schema"]
636636

637637
target_namespace = [
638-
s.lower() for s in target_type_name.split("::")
638+
safe_reserved(s.lower()) for s in target_type_name.split("::")
639639
] # AWS::SQS::Queue -> awssqsqueue
640640
target_name = "".join(
641641
[s.capitalize() for s in target_namespace]

0 commit comments

Comments
 (0)