Index: WAeUP_SRP/base/WAeUPTool.py
===================================================================
--- WAeUP_SRP/base/WAeUPTool.py	(revision 2358)
+++ WAeUP_SRP/base/WAeUPTool.py	(revision 2363)
@@ -690,4 +690,16 @@
     ###)
 
+    security.declarePublic('picturesExist') ###(
+    def picturesExist(self, ids):
+        """check if pictures exist in the filesystem"""
+        path = 'images'
+        student_id = self.getStudentId()
+        picture_path = os.path.join(i_home,path,student_id)
+        if not os.path.exists(picture_path):
+            return False
+        pictures  = [picture[:picture.rfind('_')] for picture in os.listdir(picture_path)]
+        return set(ids).issubset(set(pictures))
+    ###)
+
     security.declarePublic('showFsPicture') ###(
     def showFsPicture(self,path):
@@ -705,6 +717,4 @@
         if os.path.exists(picture_path):
             return open(picture_path).read()
-
-
     ###)
 
Index: WAeUP_SRP/base/skins/waeup_student/clearance_edit.py
===================================================================
--- WAeUP_SRP/base/skins/waeup_student/clearance_edit.py	(revision 2358)
+++ WAeUP_SRP/base/skins/waeup_student/clearance_edit.py	(revision 2363)
@@ -49,4 +49,6 @@
                   )
 required_scans = ('fst_sit_scan',
+                  'age_dec',
+                  'birth_certificate',
 #                 'jamb_slip',
                   'ref_let',
@@ -96,38 +98,16 @@
         logger.info('%s edited clearance object of %s' % (member_id,student_id ))
 
-        ## No idea why the following lines were still active until July 6.
-        ## The code does not make any sense. When editing the clearance object 
-        ## as admin, always the PIN HOS-1-4921190317
-        ## was filled in. This was the only PIN ever used by admin.
-        
-        #if clear_doc.clr_ac_pin == "":
-        #    res = context.portal_pins(student=member_id)
-        #    if res:
-        #        p = res[0].pin
-        #        if len(p) > 10:
-        #            pin = "%s-%s-%s" % (p[:3],p[3:4],p[4:])
-        #        else:
-        #            pin = p
-        #        clear_doc.edit(mapping={'clr_ac_pin': pin})
-
-        ## simple method to remove the wrong PIN
-        
-        #if clear_doc.clr_ac_pin.startswith('HOS'):
-        #    pin=''
-        #    clear_doc.edit(mapping={'clr_ac_pin': pin})
-
-
     elif cpsdocument_edit_and_view_button:
         if acknowledge and info['review_state'] == "clearance_pin_entered":
             missing = False
-            files = clear_doc.objectIds()
-            for scan in required_scans:
-                if scan not in files:
-                    missing = True
-                    break
-            if not missing:
-                if not "age_dec" in files and not "birth_certificate" in files:
-                    missing = True
-            if missing:
+            #files = clear_doc.objectIds()
+            # for scan in required_scans:
+            #     if scan not in files:
+            #         missing = True
+            #         break
+            # if not missing:
+            #     if not "age_dec" in files and not "birth_certificate" in files:
+            #         missing = True
+            if not context.waeup_tool.picturesExist(required_scans):
                 logger.info('%s requested clearance with documents missing' % (student_id))
                 psm = "You have not uploaded all necessary documents to request clearance!"
