def is_self_paced(course):
 return (course and course.self_paced and SelfPacedConfiguration.current().enabled)

def is_self_paced ( course ) : return ( course and course . self_paced and SelfPacedConfiguration . current ( ) . enabled )
returns true if course is self-paced .