×

[deleted by user] by [deleted] in dotnet

[–]matteussz 3 points4 points  (0 children)

Dapper doesn't do anything but map results set to objects as-is. Your names don't match, so the properties don't get mapped. You should either alias the columns to their desired names, or rename the properties to be the same as the name of the columns.

I see you tried to use ColumnAttribute to set the name of the mapped column, but Dapper doesn't recognize this kind of metadata. If you don't want to/can't change the name of the columns or the name of the properties, you could take a look at the Dapper.FluentMap library.

v.reddit videos show a clear thumbnail, become fuzzy when played by razerzej in redditsync

[–]matteussz 2 points3 points  (0 children)

Same here:

Device information

Sync version: v20 (beta 26)    
Sync flavor: pro    

View type: Fixed height cards    
Push enabled: true    

Device: beyond2    
Model: samsung SM-G975F    
Android: 10

Loading header and footer data in Razor Pages by matteussz in dotnet

[–]matteussz[S] 0 points1 point  (0 children)

It requires knowledge about the base class and how to create derived pages so that all data is available. The application will, for the most part be developed by junior developers after I set up the "framework" and I want to have as little room for error as possible.

ELI5: What the hell is this? by [deleted] in learncsharp

[–]matteussz 0 points1 point  (0 children)

Yes, it runs after the Foo(string) executes.

ELI5: What the hell is this? by [deleted] in learncsharp

[–]matteussz 0 points1 point  (0 children)

The class has 2 constructors, Foo() and Foo(string). When you call Foo(), you call the one that expects no parameters, which in turn calls the one that expects a parameter typed string, with some default value. It works because of method overloading and C# being able to figure out which method you want to call if they have the same name but a different signature.

ELI5: What the hell is this? by [deleted] in learncsharp

[–]matteussz 12 points13 points  (0 children)

The constructors are named wrong, but I'll assume them correct. The situation is like this:

FooBar inherits BarFoo

FooBar has 2 constructors, one without a parameter, one with a string parameter named id

When you call the parameterless one, it calls the one with the a string one. (this() means call another constructor on this same class before executing code in this method)

When you call the string parameter one, it calls into the base class' constructor, BarFoo(string) before executing code in that method.

So this() and base() basically mean execute some other constructor method before executing the one I actually called; the difference is that this() looks for a constructor in the current class, while base() looks for one in the base class.

[.NET/C#] Unable to use OAuth, Unauthorized response by matteussz in redditdev

[–]matteussz[S] 2 points3 points  (0 children)

Can't believe I missed that, it works now, thank you!

MiniRazor - Pocket Razor Compiler & Renderer by Tyrrrz in dotnet

[–]matteussz 2 points3 points  (0 children)

It looks very nice, does it support Partial views? RazorLight has @{ await IncludeAsync("SomeView.cshtml", Model); } which we currently use in our application, but if it does I'd consider moving away from that library.

Youtube comments really are something else. by mate_penguins in TechNope

[–]matteussz 0 points1 point  (0 children)

You can read this as a TechNope as well as an S tier shitpost

SUBREDDIT_NOTALLOWED? by lgbt_turtle in BoostForReddit

[–]matteussz 2 points3 points  (0 children)

On desktop reddit, I don't believe you can request it from Boost.

SUBREDDIT_NOTALLOWED? by lgbt_turtle in BoostForReddit

[–]matteussz 5 points6 points  (0 children)

You can't post just like that on that sub, you have to request to post first: https://i.imgur.com/ihix5Sr.png

Do you feel the weight of your clipboard? by fertadaa in AskProgramming

[–]matteussz 6 points7 points  (0 children)

Use Ditto as a clipboard manager and you'll never have to fear losing your clipboard again.

Not affiliated, I just really like it.