Changeset 265

Show
Ignore:
Timestamp:
11/04/06 19:29:41 (2 years ago)
Author:
scorfield
Message:

Fixes #99 for fusebox.xml files as well.

Location:
framework/trunk
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • framework/trunk/fuseboxApplication.cfc

    r264 r265  
    158158                <cfset var needToLoad = true /> 
    159159                <cfset var fuseboxFiles = 0 /> 
     160                <cfset var myFuseboxFilePath = "" /> 
     161                <cfset var jFuseboxFile = "" /> 
     162                <cfset var dtLastModified = "" /> 
    160163 
    161164                <cfif structKeyExists(this,"timestamp")> 
    162                         <cfdirectory action="list" directory="#this.approotdirectory#" filter="fusebox.xml*" name="fuseboxFiles" /> 
    163                         <cfif fuseboxFiles.recordCount eq 1> 
    164                                 <cfset needToLoad = parseDateTime(fuseboxFiles.dateLastModified) gt parseDateTime(this.timestamp) /> 
    165                         <!--- else ignore the ambiguity ---> 
    166                         </cfif> 
     165                        <cfif not fileExists(this.approotdirectory & fbFile)> 
     166                                <cfset fbFile = "fusebox.xml" /> 
     167                        </cfif> 
     168                        <!--- Java timestamp solution provided by Daniel Schmid ---> 
     169                        <cfset myFuseboxFilePath = this.approotdirectory & fbFile /> 
     170                        <cfset jFuseboxFile = createObject("java","java.io.File").init(myFuseboxFilePath) /> 
     171                        <cfset dtLastModified = createObject("java","java.util.Date").init(jFuseboxFile.lastModified()) /> 
     172                        <cfset needToLoad = parseDateTime(dtLastModified) gt parseDateTime(this.timestamp) /> 
    167173                </cfif> 
    168174 
  • framework/trunk/myFusebox.cfc

    r264 r265  
    5151<cfcomponent hint="I provide the per-request myFusebox data structure and some convenience methods."> 
    5252        <cfscript> 
    53         // fixed ticket 99 again 
     53        // fixed ticket 99 for fusebox files 
    5454        this.version.runtime     = "5.0.1.#REReplace('$LastChangedRevision$','[^0-9]','','all')#"; 
    5555