Skip to content

GET FILE REQUEST NOT WORKING #6

@FrankDupree

Description

@FrankDupree

Can't seem to get a file, the get endpoint just returns nothing. Post works well, even deleting a file works. Just cant seem to fetch a file.

Also, The application throws the following error.
System.IO.FileNotFoundException: 'Could not find file 'C:\Users\xxxx\Documents\Visual Studio 2017\Projects\xxxx\Services\FileServer\Filo\wwwroot\.json'.'

 public T Get<T>(Uri uri) where T : MetaInfo
        {
            var metafile = GetFile(uri);
            using (var reader = new StreamReader(new FileStream(metafile, FileMode.Open)))
            {
                return JsonConvert.DeserializeObject<T>(reader.ReadToEnd());
            }
        }

public T Get<T>(Uri uri) where T : MetaInfo

Whats the purpose of the .json file, placing it works but i mean why?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions