Article 406 [source]

Spanish Criminal Code
English translation

The same fine penalty will be imposed on the person who accepts the proposal, appointment or taking of office mentioned in the previous article, knowing that he or she lacks the legally required qualifications.