| 
									
										
										
										
											2020-02-25 10:20:14 +01:00
										 |  |  | // this can go once all certs have been audited.
 | 
					
						
							| 
									
										
										
										
											2021-01-31 14:53:27 +01:00
										 |  |  | 
 | 
					
						
							|  |  |  | // Currently the auditing is going through Crowdin, so once a cert has been 100%
 | 
					
						
							|  |  |  | // proofread, we can add it in here. That means that translations can come
 | 
					
						
							|  |  |  | // through from Crowdin whenever they are done, but we don't show them on the
 | 
					
						
							|  |  |  | // client until we decide the entire cert is ready.
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-02-11 13:40:32 +01:00
										 |  |  | // NOTE: certificates themselves (.yml files) are not currently being
 | 
					
						
							| 
									
										
										
										
											2021-01-31 14:53:27 +01:00
										 |  |  | // translated, but when they are they can be included by adding 'certificates'
 | 
					
						
							|  |  |  | // to the arrays below
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-06-15 23:07:52 +05:30
										 |  |  | const { auditedCerts } = require('../config/i18n/all-langs'); | 
					
						
							| 
									
										
										
										
											2021-01-31 14:53:27 +01:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-02-25 10:20:14 +01:00
										 |  |  | function isAuditedCert(lang, cert) { | 
					
						
							|  |  |  |   if (!lang || !cert) | 
					
						
							|  |  |  |     throw Error('Both arguments must be provided for auditing'); | 
					
						
							| 
									
										
										
										
											2021-01-31 14:53:27 +01:00
										 |  |  |   return lang === 'english' || auditedCerts[lang].includes(cert); | 
					
						
							| 
									
										
										
										
											2020-02-25 10:20:14 +01:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | exports.isAuditedCert = isAuditedCert; |