§1. A promissory oath follows the nature and conditions of the act to which it is attached.
§2. If an oath is added to an act which directly tends toward the harm of others or toward the disadvantage of the public good or of eternal salvation, then the act is not reinforced by the oath.
Source: Code of Canon Law (Vatican.va)