In the first case token is true for Tokens and false for Ether, in the second case eth is true for Ether and false for Tokens. This will likely lead to mixups between the two when people are interacting with the contract.
Use an enum such as enum CoinType {token, ether} instead to keep the arguments consistent and apparent to anyone using the contract.
In the contract code there are places such as the following:
In the first case
token
istrue
for Tokens andfalse
for Ether, in the second caseeth
istrue
for Ether andfalse
for Tokens. This will likely lead to mixups between the two when people are interacting with the contract.Use an enum such as
enum CoinType {token, ether}
instead to keep the arguments consistent and apparent to anyone using the contract.