fix(connector): keep connector name type as binary don't convert it to atom
After investigation, it was confirmed that there was no need to convert the connector name to atom
This commit is contained in:
parent
6c52d5de1f
commit
d0687c7aaa
|
@ -78,9 +78,10 @@ connector_id(Type0, Name0) ->
|
|||
Name = bin(Name0),
|
||||
<<Type/binary, ":", Name/binary>>.
|
||||
|
||||
-spec parse_connector_id(binary() | list() | atom()) -> {atom(), binary()}.
|
||||
parse_connector_id(ConnectorId) ->
|
||||
case string:split(bin(ConnectorId), ":", all) of
|
||||
[Type, Name] -> {binary_to_atom(Type, utf8), binary_to_atom(Name, utf8)};
|
||||
[Type, Name] -> {binary_to_atom(Type, utf8), Name};
|
||||
_ -> error({invalid_connector_id, ConnectorId})
|
||||
end.
|
||||
|
||||
|
|
Loading…
Reference in New Issue